OSDN Git Service

[VM][WIP] Use namespace to devices per VMs.
[csp-qt/common_source_project-fm7.git] / source / src / vm / hc20 / memory.h
index 6f47b67..7703fde 100644 (file)
@@ -7,8 +7,8 @@
        [ memory ]
 */
 
-#ifndef _MEMORY_H_
-#define _MEMORY_H_
+#ifndef _HC20_MEMORY_H_
+#define _HC20_MEMORY_H_
 
 #include "../vm.h"
 #include "../../emu.h"
@@ -26,6 +26,8 @@
 class BEEP;
 class FIFO;
 
+namespace HC20 {
+
 class MEMORY : public DEVICE
 {
 private:
@@ -106,9 +108,7 @@ public:
        uint32_t read_data8(uint32_t addr);
        void write_signal(int id, uint32_t data, uint32_t mask);
        void event_callback(int event_id, int err);
-       void decl_state();
-       void save_state(FILEIO* state_fio);
-       bool load_state(FILEIO* state_fio);
+       bool process_state(FILEIO* state_fio, bool loading);
        
        // unique functions
        void set_context_beep(BEEP* device)
@@ -140,5 +140,6 @@ public:
        void draw_screen();
 };
 
+}
 #endif