From 0a76cc9b03e2136b89f865d90336adbcdcf63989 Mon Sep 17 00:00:00 2001 From: Jeff Long Date: Thu, 12 Oct 2023 17:21:30 -0400 Subject: [PATCH 1/2] bookmarks: restore Delete key Delete is used as a global shortcut to clear the waterfall. It is also used to delete a bookmark, when the bookmarks table has focus. Allow the bookmarks table to override the global Delete shortcut. Signed-off-by: Jeff Long --- src/qtgui/dockbookmarks.cpp | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/src/qtgui/dockbookmarks.cpp b/src/qtgui/dockbookmarks.cpp index 5511d6968..ff518588d 100644 --- a/src/qtgui/dockbookmarks.cpp +++ b/src/qtgui/dockbookmarks.cpp @@ -158,12 +158,20 @@ void DockBookmarks::on_tableWidgetTagList_itemChanged(QTableWidgetItem *item) bool DockBookmarks::eventFilter(QObject* object, QEvent* event) { - if (event->type() == QEvent::KeyPress) + // Since Key_Delete can be (is) used as a global shortcut, override the + // shortcut. Accepting a ShortcutOverride causes the event to be delivered + // again, but as a KeyPress. + if (event->type() == QEvent::KeyPress || event->type() == QEvent::ShortcutOverride) { QKeyEvent* pKeyEvent = static_cast(event); - if (pKeyEvent->key() == Qt::Key_Delete && ui->tableViewFrequencyList->hasFocus()) + if (pKeyEvent->key() == Qt::Key_Delete) { - return DeleteSelectedBookmark(); + if (event->type() == QEvent::ShortcutOverride) { + event->accept(); + } + else { + return DeleteSelectedBookmark(); + } } } return QWidget::eventFilter(object, event); From 03ebc21815eb9ead9cca97ffa5ca3a0a1651e564 Mon Sep 17 00:00:00 2001 From: Clayton Smith Date: Thu, 19 Oct 2023 16:25:46 -0400 Subject: [PATCH 2/2] Update news --- resources/news.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/resources/news.txt b/resources/news.txt index 7311de9aa..14f04be2e 100644 --- a/resources/news.txt +++ b/resources/news.txt @@ -1,4 +1,9 @@ + 2.17.3: In progress... + + FIXED: Delete key shortcut for bookmark removal. + + 2.17.2: Released October 9, 2023 NEW: FORCE_QT6 and FORCE_QT5 CMake options to force Qt version.