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.
This commit is contained in:
Fushan Wen 2021-10-31 09:16:59 +08:00 committed by Nate Graham
parent f4ca7a43c1
commit 2d93b625e2
2 changed files with 2 additions and 2 deletions

View file

@ -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 {

View file

@ -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();
}