From 832597f9262b9066bfd660011afdec81ae90b09a Mon Sep 17 00:00:00 2001 From: Devin Lin Date: Mon, 15 Dec 2025 19:17:46 -0500 Subject: [PATCH] gestures: Trigger task switcher when mouse pulls up on gesture bar As a stopgap until we have https://invent.kde.org/plasma/plasma-mobile/-/issues/492, simply trigger the task switcher when a mouse pulls up on the gesture bar. --- .../qml/navigationpanel/GesturePanel.qml | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/components/mobileshell/qml/navigationpanel/GesturePanel.qml b/components/mobileshell/qml/navigationpanel/GesturePanel.qml index 76e84ebd..eac76ea1 100644 --- a/components/mobileshell/qml/navigationpanel/GesturePanel.qml +++ b/components/mobileshell/qml/navigationpanel/GesturePanel.qml @@ -35,6 +35,19 @@ Rectangle { onClicked: root.handleClicked() onPressAndHold: root.handlePressedAndHeld() + property real startX + property real startY + onPressed: { + startX = mouseX; + startY = mouseY; + } + onPositionChanged: (mouse) => { + // Trigger gesture after threshold is crossed (root.height) + if (startY - mouse.y > root.height) { + root.handleClicked(); + } + } + Rectangle { anchors.centerIn: parent width: parent.width