From df3f3d3d7b13fe4668f0b3b931c39d7599e288c1 Mon Sep 17 00:00:00 2001 From: Pascal Precht <445106+PascalPrecht@users.noreply.github.com> Date: Mon, 7 Nov 2022 15:56:59 +0100 Subject: [PATCH] fix(AppSearch): ensure app search loader is deactivated when popup is closed Otherwise, the loader stays active, which requires users to hit CTRL-F twice to reopen it again (because it'll first deactivate, then activate again). Fixes #7989 --- ui/app/mainui/AppMain.qml | 2 ++ ui/app/mainui/AppSearch.qml | 3 +++ 2 files changed, 5 insertions(+) diff --git a/ui/app/mainui/AppMain.qml b/ui/app/mainui/AppMain.qml index 1c8e8e15ad..47b118d3c0 100644 --- a/ui/app/mainui/AppMain.qml +++ b/ui/app/mainui/AppMain.qml @@ -286,11 +286,13 @@ Item { function closeSearchPopup() { if (item) item.closeSearchPopup() + active = false } sourceComponent: AppSearch { store: appMain.rootStore.appSearchStore + onClosed: appSearch.active = false } } diff --git a/ui/app/mainui/AppSearch.qml b/ui/app/mainui/AppSearch.qml index e745a0b5bb..730bfaab7d 100644 --- a/ui/app/mainui/AppSearch.qml +++ b/ui/app/mainui/AppSearch.qml @@ -14,6 +14,8 @@ Item { }) property alias opened: searchPopup.opened + signal closed() + function openSearchPopup(){ searchPopup.open() } @@ -72,6 +74,7 @@ Item { } onClosed: { searchPopupMenu.dismiss(); + appSearch.closed(); } onResetSearchLocationClicked: { searchPopup.resetSearchSelection();