From 99324c12fd6b689809aad77ea3cb852d89982273 Mon Sep 17 00:00:00 2001 From: Nate Graham Date: Thu, 11 Apr 2024 07:33:09 -0600 Subject: [PATCH] plugins/overview: remove middle click to close virtual desktop This is a hidden destructive action[1] in a context where users are not primed to expect it. It's also largely unnecessary since the delegates already show a delete button on hover, and deleting virtual desktops isn't such a common task that it benefits from an accelerator. Let's remove it for safety. [1] It's destructive because user-created state on the deleted virtual desktop is lost--with no confirmation or undo, to boot. BUG: 484999 FIXED-IN: 6.1 --- src/plugins/overview/qml/DesktopBar.qml | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/src/plugins/overview/qml/DesktopBar.qml b/src/plugins/overview/qml/DesktopBar.qml index 74da9a6393..9c6a1442c4 100644 --- a/src/plugins/overview/qml/DesktopBar.qml +++ b/src/plugins/overview/qml/DesktopBar.qml @@ -149,17 +149,10 @@ Item { MouseArea { id: mouseArea anchors.fill: parent - acceptedButtons: Qt.LeftButton | Qt.MiddleButton + acceptedButtons: Qt.LeftButton onClicked: mouse => { mouse.accepted = true; - switch (mouse.button) { - case Qt.LeftButton: - delegate.activate(); - break; - case Qt.MiddleButton: - delegate.remove(); - break; - } + delegate.activate(); } }