From 2d93b625e26a91c2eeb3db4dade7c141e9ed50c3 Mon Sep 17 00:00:00 2001 From: Fushan Wen Date: Sun, 31 Oct 2021 09:16:59 +0800 Subject: [PATCH] effects/overview: Always show the delete button when tablet mode is on It's very difficult for touch screen users to discover the delete button, so make the delete button always visible when tablet mode is on. --- src/effects/overview/qml/DesktopBar.qml | 2 +- src/effects/overview/qml/WindowHeap.qml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/effects/overview/qml/DesktopBar.qml b/src/effects/overview/qml/DesktopBar.qml index d48d97db95..6b9f0cd7dc 100644 --- a/src/effects/overview/qml/DesktopBar.qml +++ b/src/effects/overview/qml/DesktopBar.qml @@ -147,7 +147,7 @@ Item { Loader { LayoutMirroring.enabled: Qt.application.layoutDirection == Qt.RightToLeft - active: hoverHandler.hovered && desktopRepeater.count > 1 + active: (hoverHandler.hovered || Kirigami.Settings.tabletMode || Kirigami.Settings.hasTransientTouchInput) && desktopRepeater.count > 1 anchors.right: parent.right anchors.top: parent.top sourceComponent: PC3.Button { diff --git a/src/effects/overview/qml/WindowHeap.qml b/src/effects/overview/qml/WindowHeap.qml index 3b643af589..de4880035e 100644 --- a/src/effects/overview/qml/WindowHeap.qml +++ b/src/effects/overview/qml/WindowHeap.qml @@ -260,7 +260,7 @@ FocusScope { anchors.topMargin: PlasmaCore.Units.largeSpacing implicitWidth: PlasmaCore.Units.iconSizes.medium implicitHeight: implicitWidth - visible: (hovered || hoverHandler.hovered) && thumb.client.closeable && !dragHandler.active + visible: (hovered || hoverHandler.hovered || Kirigami.Settings.tabletMode || Kirigami.Settings.hasTransientTouchInput) && thumb.client.closeable && !dragHandler.active onClicked: thumb.client.closeWindow(); }