summaryrefslogtreecommitdiff
path: root/modules/launcher/Content.qml
diff options
context:
space:
mode:
author2 * r + 2 * t <61896496+soramanew@users.noreply.github.com>2025-09-12 18:04:44 +1000
committer2 * r + 2 * t <61896496+soramanew@users.noreply.github.com>2025-09-12 18:04:44 +1000
commit302a82da2dda3f1b8f86649bd801697f9f3c2209 (patch)
tree1c8763acb83aa01102c9f7587f6a0e02890a6a00 /modules/launcher/Content.qml
parentosd: loader content (diff)
downloadcaelestia-shell-302a82da2dda3f1b8f86649bd801697f9f3c2209.tar.gz
caelestia-shell-302a82da2dda3f1b8f86649bd801697f9f3c2209.tar.bz2
caelestia-shell-302a82da2dda3f1b8f86649bd801697f9f3c2209.zip
launcher: loader content
Diffstat (limited to 'modules/launcher/Content.qml')
-rw-r--r--modules/launcher/Content.qml20
1 files changed, 6 insertions, 14 deletions
diff --git a/modules/launcher/Content.qml b/modules/launcher/Content.qml
index 7158cdd..f4e1b45 100644
--- a/modules/launcher/Content.qml
+++ b/modules/launcher/Content.qml
@@ -11,7 +11,6 @@ import QtQuick
Item {
id: root
- required property var wrapper
required property PersistentProperties visibilities
required property var panels
@@ -21,9 +20,6 @@ Item {
implicitWidth: listWrapper.width + padding * 2
implicitHeight: searchWrapper.height + listWrapper.height + padding * 2
- anchors.top: parent.top
- anchors.horizontalCenter: parent.horizontalCenter
-
Item {
id: listWrapper
@@ -37,7 +33,7 @@ Item {
ContentList {
id: list
- wrapper: root.wrapper
+ content: root
visibilities: root.visibilities
panels: root.panels
search: search
@@ -129,23 +125,19 @@ Item {
}
}
+ Component.onCompleted: forceActiveFocus()
+
Connections {
target: root.visibilities
function onLauncherChanged(): void {
- if (root.visibilities.launcher)
- search.focus = true;
- else {
+ if (!root.visibilities.launcher)
search.text = "";
- const current = list.currentList;
- if (current)
- current.currentIndex = 0;
- }
}
function onSessionChanged(): void {
- if (root.visibilities.launcher && !root.visibilities.session)
- search.focus = true;
+ if (!root.visibilities.session)
+ search.forceActiveFocus();
}
}
}