From d47c50edaf4182e3cbee1c2d0516d254f9ea2cdb Mon Sep 17 00:00:00 2001 From: tildearrow Date: Sun, 19 Jun 2022 18:23:44 -0500 Subject: [PATCH] GUI: fix drag to move --- src/gui/cursor.cpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/gui/cursor.cpp b/src/gui/cursor.cpp index 4b75a26ad..ee681c77a 100644 --- a/src/gui/cursor.cpp +++ b/src/gui/cursor.cpp @@ -91,6 +91,19 @@ void FurnaceGUI::updateSelection(int xCoarse, int xFine, int y, bool fullRow) { cursorDrag.xFine=xFine; cursorDrag.y=y; + int len=dragEnd.xCoarse-dragStart.xCoarse+1; + if (len<0) len=0; + + DETERMINE_FIRST_LAST; + + if (dragStart.xCoarse+(dragDestinationX-dragSourceX)lastChannel) { + + } + selStart.xCoarse=dragStart.xCoarse+(dragDestinationX-dragSourceX); selStart.xFine=dragStart.xFine; selStart.y=dragStart.y+(dragDestinationY-dragSourceY);