diff --git a/src/app/editor/master_editor.cc b/src/app/editor/master_editor.cc index bd4f8016..c0d1e500 100644 --- a/src/app/editor/master_editor.cc +++ b/src/app/editor/master_editor.cc @@ -215,6 +215,13 @@ void MasterEditor::DrawViewMenu() { static bool show_imgui_demo = false; static bool show_memory_viewer = false; static bool show_palette_editor = false; + static bool show_emulator = false; + + if (show_emulator) { + ImGui::Begin("Emulator", &show_emulator, ImGuiWindowFlags_MenuBar); + emulator_.Run(); + ImGui::End(); + } if (show_imgui_metrics) { ImGui::ShowMetricsWindow(&show_imgui_metrics); @@ -269,6 +276,7 @@ void MasterEditor::DrawViewMenu() { } if (ImGui::BeginMenu("View")) { + ImGui::MenuItem("Emulator", nullptr, &show_emulator); ImGui::MenuItem("HEX Editor", nullptr, &show_memory_editor); ImGui::MenuItem("ASM Editor", nullptr, &show_asm_editor); ImGui::MenuItem("Palette Editor", nullptr, &show_palette_editor); diff --git a/src/app/editor/master_editor.h b/src/app/editor/master_editor.h index 1e38cf7f..8d645ee6 100644 --- a/src/app/editor/master_editor.h +++ b/src/app/editor/master_editor.h @@ -9,6 +9,7 @@ #include "absl/status/status.h" #include "app/core/constants.h" +#include "app/core/emulator.h" #include "app/core/pipeline.h" #include "app/editor/assembly_editor.h" #include "app/editor/dungeon_editor.h" @@ -64,6 +65,7 @@ class MasterEditor : public SharedROM { std::shared_ptr sdl_renderer_; + core::Emulator emulator_; AssemblyEditor assembly_editor_; DungeonEditor dungeon_editor_; GraphicsEditor graphics_editor_;