mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-04-26 14:23:09 +00:00
homescreens: also close the search widget with Meta key
This commit is contained in:
parent
f4e6d6b69a
commit
838826b4fd
3 changed files with 11 additions and 0 deletions
|
|
@ -58,6 +58,7 @@ Item {
|
|||
readonly property real closedContentY: PlasmaCore.Units.gridUnit * 5
|
||||
readonly property real openedContentY: 0
|
||||
readonly property real openFactor: Math.max(0, Math.min(1, 1 - flickable.contentY / closedContentY))
|
||||
readonly property bool isOpen: openFactor != 0
|
||||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
|
|
|
|||
|
|
@ -46,6 +46,11 @@ MobileShell.HomeScreen {
|
|||
MobileShell.TopPanelControls.closeActionDrawer();
|
||||
}
|
||||
|
||||
// Always close the search widget as well
|
||||
if (searchWidget.isOpen) {
|
||||
searchWidget.close();
|
||||
}
|
||||
|
||||
// there's a couple of steps:
|
||||
// - minimize windows (only if we are in an app)
|
||||
// - open app drawer
|
||||
|
|
|
|||
|
|
@ -45,6 +45,11 @@ MobileShell.HomeScreen {
|
|||
MobileShell.TopPanelControls.closeActionDrawer();
|
||||
}
|
||||
|
||||
// Always close the search widget as well
|
||||
if (search.isOpen) {
|
||||
search.close();
|
||||
}
|
||||
|
||||
// there's a couple of steps:
|
||||
// - minimize windows (only if we are in an app)
|
||||
// - open app drawer
|
||||
|
|
|
|||
Loading…
Reference in a new issue