mirror of
https://github.com/danbulant/dots-hyprland
synced 2026-05-24 12:22:09 +00:00
clipboard history: remove unnecessary refreshes
This commit is contained in:
parent
89203e8794
commit
4b0ee5b8ab
2 changed files with 0 additions and 11 deletions
|
|
@ -192,7 +192,6 @@ Scope {
|
|||
GlobalStates.overviewOpen = false;
|
||||
return;
|
||||
}
|
||||
Cliphist.refresh()
|
||||
for (let i = 0; i < overviewVariants.instances.length; i++) {
|
||||
let panelWindow = overviewVariants.instances[i];
|
||||
if (panelWindow.modelData.name == Hyprland.focusedMonitor.name) {
|
||||
|
|
|
|||
|
|
@ -23,11 +23,6 @@ Item { // Wrapper
|
|||
implicitHeight: searchWidgetContent.implicitHeight + Appearance.sizes.elevationMargin * 2
|
||||
|
||||
property string mathResult: ""
|
||||
property bool lastQueryWasClipboard: false
|
||||
|
||||
onShowResultsChanged: {
|
||||
lastQueryWasClipboard = false;
|
||||
}
|
||||
|
||||
function disableExpandAnimation() {
|
||||
searchWidthBehavior.enabled = false;
|
||||
|
|
@ -298,10 +293,6 @@ Item { // Wrapper
|
|||
|
||||
///////////// Special cases ///////////////
|
||||
if (root.searchingText.startsWith(ConfigOptions.search.prefix.clipboard)) { // Clipboard
|
||||
if (!root.lastQueryWasClipboard) {
|
||||
root.lastQueryWasClipboard = true;
|
||||
Cliphist.refresh(); // Refresh clipboard entries
|
||||
}
|
||||
const searchString = root.searchingText.slice(ConfigOptions.search.prefix.clipboard.length);
|
||||
return Cliphist.fuzzyQuery(searchString).map(entry => {
|
||||
return {
|
||||
|
|
@ -311,7 +302,6 @@ Item { // Wrapper
|
|||
type: `#${entry.match(/^\s*(\S+)/)?.[1] || ""}`,
|
||||
execute: () => {
|
||||
Hyprland.dispatch(`exec echo '${StringUtils.shellSingleQuoteEscape(entry)}' | cliphist decode | wl-copy`);
|
||||
Cliphist.refresh()
|
||||
}
|
||||
};
|
||||
}).filter(Boolean);
|
||||
|
|
|
|||
Loading…
Reference in a new issue