diff --git a/NEWS.md b/NEWS.md index 75eeb84f..845b6f60 100644 --- a/NEWS.md +++ b/NEWS.md @@ -17,6 +17,7 @@ Red Panda C++ Version 1.0.1 - enhancement: slightly reduce memory usage for code parser - enhancement: switch capslock won't cancel code completion - enhancement: double click on item in code completion list will use it to complete + - fix: goto declaration by ctrl+click will incorrectly select contents Red Panda C++ Version 1.0.0 - fix: calculation for code snippets's tab stop positions is not correct diff --git a/RedPandaIDE/qsynedit/SynEdit.cpp b/RedPandaIDE/qsynedit/SynEdit.cpp index ff689dcf..85b466b3 100644 --- a/RedPandaIDE/qsynedit/SynEdit.cpp +++ b/RedPandaIDE/qsynedit/SynEdit.cpp @@ -1824,6 +1824,9 @@ void SynEdit::doMouseScroll(bool isDragging) mDropped=false; return; } + Qt::MouseButtons buttons = qApp->mouseButtons(); + if (!buttons.testFlag(Qt::LeftButton)) + return; QPoint iMousePos; DisplayCoord C; int X, Y; @@ -2532,9 +2535,6 @@ void SynEdit::computeScroll(bool isDragging) int X=iMousePos.x(); int Y=iMousePos.y(); - Qt::MouseButtons buttons = qApp->mouseButtons(); - if (!buttons.testFlag(Qt::LeftButton)) - return; QRect iScrollBounds; // relative to the client area int dispX=2,dispY = 2; // if (isDragging) {