diff --git a/panels/dock/package/main.qml b/panels/dock/package/main.qml index ded6c54e4..68e8931e6 100644 --- a/panels/dock/package/main.qml +++ b/panels/dock/package/main.qml @@ -388,6 +388,7 @@ Window { id: dockContainer width: dock.useColumnLayout ? dock.dockSize : parent.width height: dock.useColumnLayout ? parent.height : dock.dockSize + property bool touchLongPressed: false anchors { left: parent.left top: parent.top @@ -437,6 +438,10 @@ Window { acceptedButtons: Qt.NoButton acceptedDevices: PointerDevice.TouchScreen onTapped: function(eventPoint, button) { + if (dockContainer.touchLongPressed) { + dockContainer.touchLongPressed = false + return + } let lastActive = MenuHelper.activeMenu MenuHelper.closeCurrent() dockMenuLoader.active = true @@ -445,6 +450,7 @@ Window { viewDeactivated() } onLongPressed: { + dockContainer.touchLongPressed = true let lastActive = MenuHelper.activeMenu MenuHelper.closeCurrent() dockMenuLoader.active = true @@ -452,6 +458,9 @@ Window { requestShowDockMenu() } } + onCanceled: { + dockContainer.touchLongPressed = false + } } HoverHandler {