diff --git a/qml/AppUI/AppPageSearch.qml b/qml/AppUI/AppPageSearch.qml index 6572995..8b3118b 100644 --- a/qml/AppUI/AppPageSearch.qml +++ b/qml/AppUI/AppPageSearch.qml @@ -30,6 +30,10 @@ Item { inputStatus = true; } } + + Component.onCompleted: { + text = root.currentSearchText; + } } function changeToSearch(keyEvent) { diff --git a/qml/AppUI/FullScreenUI.qml b/qml/AppUI/FullScreenUI.qml index 21e0156..c1cf4c9 100644 --- a/qml/AppUI/FullScreenUI.qml +++ b/qml/AppUI/FullScreenUI.qml @@ -142,6 +142,10 @@ FocusScope { AppPageBackend.startSearch(text); } } + + Component.onCompleted: { + text = root.currentSearchText; + } } } diff --git a/qml/AppUI/Sidebar.qml b/qml/AppUI/Sidebar.qml index 18dda64..2a5aacb 100644 --- a/qml/AppUI/Sidebar.qml +++ b/qml/AppUI/Sidebar.qml @@ -53,8 +53,10 @@ Item { onClicked: { if (mainWindow.isFullScreen) { + root.currentSearchText = searchInputBar.text; mainWindow.exitFullScreen(); } else { + root.currentSearchText = appPage.search.searchInputBar.text; mainWindow.isFullScreen = true; } } diff --git a/qml/main.qml b/qml/main.qml index 7768584..dfc063e 100644 --- a/qml/main.qml +++ b/qml/main.qml @@ -28,6 +28,7 @@ Item { clip: true property int animationDuration: menuSetting.get("animationDuration") property var normalGeometry: mainWindow.normalRect + property string currentSearchText: "" Component.onCompleted: { mainWindow.fullScreenChanged.connect(enterFullScreen);