mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-04-26 14:23:09 +00:00
Add close button to app drawer header in convergence
On desktop there is no swipe-down gesture to dismiss the drawer. Add an X button at the right end of the header row, visible only in convergence mode, so mouse users have an obvious way to close the app drawer.
This commit is contained in:
parent
d18c2acadb
commit
1200740f6b
1 changed files with 14 additions and 0 deletions
|
|
@ -8,6 +8,7 @@ import QtQuick.Layouts
|
|||
import org.kde.kirigami as Kirigami
|
||||
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.private.mobileshell.shellsettingsplugin as ShellSettings
|
||||
import plasma.applet.org.kde.plasma.mobile.homescreen.folio as Folio
|
||||
import './delegate'
|
||||
|
||||
|
|
@ -88,5 +89,18 @@ Item {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Close button for convergence mode
|
||||
QQC2.ToolButton {
|
||||
visible: ShellSettings.Settings.convergenceModeEnabled
|
||||
icon.name: "window-close-symbolic"
|
||||
icon.color: "white"
|
||||
Layout.preferredWidth: Kirigami.Units.iconSizes.medium
|
||||
Layout.preferredHeight: Kirigami.Units.iconSizes.medium
|
||||
onClicked: folio.HomeScreenState.closeAppDrawer()
|
||||
|
||||
Kirigami.Theme.inherit: false
|
||||
Kirigami.Theme.colorSet: Kirigami.Theme.Complementary
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue