From 577d6fd4d4b380acb506fc304c8cc36951fefa3a Mon Sep 17 00:00:00 2001 From: tildearrow Date: Tue, 22 Aug 2023 20:23:21 -0500 Subject: [PATCH] GUI: fix expand selection upwards --- src/gui/cursor.cpp | 12 ++++++++---- src/gui/debugWindow.cpp | 15 +++++++++++++++ 2 files changed, 23 insertions(+), 4 deletions(-) diff --git a/src/gui/cursor.cpp b/src/gui/cursor.cpp index 15f9e53f..da202845 100644 --- a/src/gui/cursor.cpp +++ b/src/gui/cursor.cpp @@ -374,7 +374,9 @@ void FurnaceGUI::moveCursorNextChannel(bool overflow) { } void FurnaceGUI::moveCursorTop(bool select) { - finishSelection(); + if (!select) { + finishSelection(); + } curNibble=false; if (cursor.y==0) { DETERMINE_FIRST; @@ -384,16 +386,18 @@ void FurnaceGUI::moveCursorTop(bool select) { } else { cursor.y=0; } - selStart=cursor; if (!select) { - selEnd=cursor; + selStart=cursor; } + selEnd=cursor; e->setMidiBaseChan(cursor.xCoarse); updateScroll(cursor.y); } void FurnaceGUI::moveCursorBottom(bool select) { - finishSelection(); + if (!select) { + finishSelection(); + } curNibble=false; if (cursor.y==e->curSubSong->patLen-1) { DETERMINE_LAST; diff --git a/src/gui/debugWindow.cpp b/src/gui/debugWindow.cpp index 9d59e44d..b3c07b07 100644 --- a/src/gui/debugWindow.cpp +++ b/src/gui/debugWindow.cpp @@ -308,6 +308,21 @@ void FurnaceGUI::drawDebug() { } ImGui::TreePop(); } + if (ImGui::TreeNode("Do Action")) { + char bindID[1024]; + for (int j=0; j