diff options
| author | littleblack111 <littleblack11111@gmail.com> | 2026-08-22 17:11:29 +0800 |
|---|---|---|
| committer | littleblack111 <littleblack11111@gmail.com> | 2026-08-22 17:14:10 +0800 |
| commit | af52ea407d10c86a2e5b5049cddb6abdee3952f8 (patch) | |
| tree | 36189e51a9d4f6075da87089c50f77c7de3e9846 | |
| parent | 78ad386209aaf20a7e122f11791e54fdcddb958b (diff) | |
fix: selectedPriority not respecting mouse
| -rw-r--r-- | popups/launcher/components/App.qml | 1 | ||||
| -rw-r--r-- | popups/launcher/components/Clip.qml | 8 | ||||
| -rw-r--r-- | popups/launcher/components/Emoji.qml | 1 | ||||
| -rw-r--r-- | popups/launcher/components/IComponent.qml | 4 | ||||
| -rw-r--r-- | popups/launcher/components/Spell.qml | 1 |
5 files changed, 11 insertions, 4 deletions
diff --git a/popups/launcher/components/App.qml b/popups/launcher/components/App.qml index 141c0ee..f3c5eeb 100644 --- a/popups/launcher/components/App.qml +++ b/popups/launcher/components/App.qml @@ -111,6 +111,7 @@ IComponent { if (selectedIndex < 0 || selectedIndex >= listView.count || !root.visible) return; + state.selectedPriority = root.getSelfPriority(); state.selected = listView.itemAtIndex(selectedIndex); }); } diff --git a/popups/launcher/components/Clip.qml b/popups/launcher/components/Clip.qml index a180b80..2552b60 100644 --- a/popups/launcher/components/Clip.qml +++ b/popups/launcher/components/Clip.qml @@ -77,6 +77,8 @@ IComponent { Qt.callLater(() => { if (!root.visible || selectedIndex < 0 || selectedIndex >= listView.count) return; + + state.selectedPriority = root.getSelfPriority(); state.selected = listView.itemAtIndex(selectedIndex); }); } @@ -188,8 +190,8 @@ IComponent { id: loader sourceComponent: clipHist[selectedIndex]?.type === "image" ? img : text property Component text: ITextEdit { - animate: true id: textEdit + animate: true readOnly: true wrapMode: TextEdit.Wrap width: preview.width @@ -209,7 +211,5 @@ IComponent { } } - Component.onCompleted: { - - } + Component.onCompleted: {} } diff --git a/popups/launcher/components/Emoji.qml b/popups/launcher/components/Emoji.qml index 8160894..88969c6 100644 --- a/popups/launcher/components/Emoji.qml +++ b/popups/launcher/components/Emoji.qml @@ -95,6 +95,7 @@ IComponent { if (!loader.view || selectedIndex < 0 || selectedIndex >= loader.view.count || !root.visible) return; + state.selectedPriority = root.getSelfPriority(); state.selected = loader.view.itemAtIndex(selectedIndex); }); } diff --git a/popups/launcher/components/IComponent.qml b/popups/launcher/components/IComponent.qml index 7450ffd..719ae94 100644 --- a/popups/launcher/components/IComponent.qml +++ b/popups/launcher/components/IComponent.qml @@ -60,6 +60,10 @@ IRect { close(); } + function getSelfPriority() { + return state.priorities.indexOf(root); + } + // this doesn't change launcher size but only hides the actual content but the outside still think the content is there visible: active opacity: valid ? 1 : 0 diff --git a/popups/launcher/components/Spell.qml b/popups/launcher/components/Spell.qml index c627b9e..8dece7e 100644 --- a/popups/launcher/components/Spell.qml +++ b/popups/launcher/components/Spell.qml @@ -118,6 +118,7 @@ IComponent { if (!loader.view || selectedIndex < 0 || selectedIndex >= loader.view.count || !root.visible) return; + state.selectedPriority = root.getSelfPriority(); state.selected = loader.view.itemAtIndex(selectedIndex); }); } |
