From e475b29ec351ad532b436f4600a24bbf7ae8a681 Mon Sep 17 00:00:00 2001 From: tildearrow Date: Tue, 13 Aug 2024 04:40:26 -0500 Subject: [PATCH] a menu --- src/engine/engine.cpp | 3 +++ src/engine/engine.h | 2 ++ src/gui/exportOptions.cpp | 22 +++++++++++++++++++++- src/gui/gui.cpp | 3 ++- src/gui/gui.h | 3 +++ 5 files changed, 31 insertions(+), 2 deletions(-) diff --git a/src/engine/engine.cpp b/src/engine/engine.cpp index 1a382b85e..bfde6906b 100644 --- a/src/engine/engine.cpp +++ b/src/engine/engine.cpp @@ -3916,6 +3916,9 @@ bool DivEngine::preInit(bool noSafeMode) { // register systems if (!systemsRegistered) registerSystems(); + // register ROM exports + if (!romExportsRegistered) registerROMExports(); + // TODO: re-enable with a better approach // see issue #1581 /* diff --git a/src/engine/engine.h b/src/engine/engine.h index 9ecf819ee..e30334fd4 100644 --- a/src/engine/engine.h +++ b/src/engine/engine.h @@ -465,6 +465,7 @@ class DivEngine { bool midiIsDirectProgram; bool lowLatency; bool systemsRegistered; + bool romExportsRegistered; bool hasLoadedSomething; bool midiOutClock; bool midiOutTime; @@ -1365,6 +1366,7 @@ class DivEngine { midiIsDirectProgram(false), lowLatency(false), systemsRegistered(false), + romExportsRegistered(false), hasLoadedSomething(false), midiOutClock(false), midiOutTime(false), diff --git a/src/gui/exportOptions.cpp b/src/gui/exportOptions.cpp index 582ba3055..c943779eb 100644 --- a/src/gui/exportOptions.cpp +++ b/src/gui/exportOptions.cpp @@ -241,7 +241,27 @@ void FurnaceGUI::drawExportVGM(bool onWindow) { void FurnaceGUI::drawExportROM(bool onWindow) { exitDisabledTimer=1; - + + const DivROMExportDef* def=e->getROMExportDef(romTarget); + + ImGui::Text("select target:"); + if (ImGui::BeginCombo("##ROMTarget",def==NULL?"