From 2fdce8512a56a3070038be2bd2abef206bc6d273 Mon Sep 17 00:00:00 2001 From: tildearrow Date: Tue, 29 Nov 2022 16:09:50 -0500 Subject: [PATCH] GUI: mobile chips view --- src/gui/gui.cpp | 5 +++++ src/gui/sysManager.cpp | 8 ++++++++ 2 files changed, 13 insertions(+) diff --git a/src/gui/gui.cpp b/src/gui/gui.cpp index eb93d3d05..9cce27f20 100644 --- a/src/gui/gui.cpp +++ b/src/gui/gui.cpp @@ -3764,6 +3764,11 @@ bool FurnaceGUI::loop() { drawSampleEdit(); drawPiano(); break; + case GUI_SCENE_CHIPS: + sysManagerOpen=true; + curWindow=GUI_WINDOW_SYS_MANAGER; + drawSysManager(); + break; default: patternOpen=true; curWindow=GUI_WINDOW_PATTERN; diff --git a/src/gui/sysManager.cpp b/src/gui/sysManager.cpp index cd82b84ca..1de5ac1f8 100644 --- a/src/gui/sysManager.cpp +++ b/src/gui/sysManager.cpp @@ -30,6 +30,14 @@ void FurnaceGUI::drawSysManager() { nextWindow=GUI_WINDOW_NOTHING; } if (!sysManagerOpen) return; + if (mobileUI) { + patWindowPos=(portrait?ImVec2(0.0f,(mobileMenuPos*-0.65*canvasH)):ImVec2((0.16*canvasH)+0.5*canvasW*mobileMenuPos,0.0f)); + patWindowSize=(portrait?ImVec2(canvasW,canvasH-(0.16*canvasW)):ImVec2(canvasW-(0.16*canvasH),canvasH)); + ImGui::SetNextWindowPos(patWindowPos); + ImGui::SetNextWindowSize(patWindowSize); + } else { + //ImGui::SetNextWindowSizeConstraints(ImVec2(440.0f*dpiScale,400.0f*dpiScale),ImVec2(canvasW,canvasH)); + } if (ImGui::Begin("Chip Manager",&sysManagerOpen,globalWinFlags)) { ImGui::Checkbox("Preserve channel order",&preserveChanPos); if (ImGui::BeginTable("SystemList",3)) {