From 36cb8b7867ad18c1fe71fe49683d69adf8a0cc6e Mon Sep 17 00:00:00 2001 From: Roy Qu Date: Wed, 7 Jun 2023 20:41:35 +0800 Subject: [PATCH] - fix: When selection is availalbe, Ctrl+Click shouldn't jump to declaration/definition. --- NEWS.md | 4 ++++ RedPandaIDE/RedPandaIDE.pro | 2 +- RedPandaIDE/editor.cpp | 2 +- Red_Panda_CPP.pro | 2 +- 4 files changed, 7 insertions(+), 3 deletions(-) diff --git a/NEWS.md b/NEWS.md index 9b972a3e..a9b54a9b 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,3 +1,7 @@ +Red Panda C++ Version 2.23 + + - fix: When selection is availalbe, Ctrl+Click shouldn't jump to declaration/definition. + Red Panda C++ Version 2.22 - fix: Crash at startup when current problem in the problem set is connected with source file. diff --git a/RedPandaIDE/RedPandaIDE.pro b/RedPandaIDE/RedPandaIDE.pro index 5cb0ab4a..e76bb30e 100644 --- a/RedPandaIDE/RedPandaIDE.pro +++ b/RedPandaIDE/RedPandaIDE.pro @@ -8,7 +8,7 @@ isEmpty(APP_NAME) { } isEmpty(APP_VERSION) { - APP_VERSION = 2.22 + APP_VERSION = 2.23 } contains(QMAKE_HOST.arch, x86_64):{ diff --git a/RedPandaIDE/editor.cpp b/RedPandaIDE/editor.cpp index fe32dce5..9706be36 100644 --- a/RedPandaIDE/editor.cpp +++ b/RedPandaIDE/editor.cpp @@ -1296,7 +1296,7 @@ void Editor::mouseReleaseEvent(QMouseEvent *event) // if ctrl+clicked if ((event->modifiers() == Qt::ControlModifier) && (event->button() == Qt::LeftButton)) { - if (!mCurrentWord.isEmpty()) { + if (!selAvail() && !mCurrentWord.isEmpty()) { QSynedit::BufferCoord p; if (mParser && pointToCharLine(event->pos(),p)) { QString s = document()->getLine(p.line - 1); diff --git a/Red_Panda_CPP.pro b/Red_Panda_CPP.pro index 642b9de8..ed89c8a0 100644 --- a/Red_Panda_CPP.pro +++ b/Red_Panda_CPP.pro @@ -14,7 +14,7 @@ qsynedit.subdir = libs/qsynedit APP_NAME = RedPandaCPP -APP_VERSION = 2.22 +APP_VERSION = 2.23 # Add the dependencies so that the RedPandaIDE project can add the depended programs # into the main app bundle