improved code by removing redundancies and done some optimizations

This commit is contained in:
SomeElse
2026-05-05 03:58:40 +00:00
parent 8f25ee5caf
commit 046a36fbec
13 changed files with 441 additions and 663 deletions

View File

@@ -129,7 +129,7 @@ PanelWindow {
launchProc.running = true
console.log("Launching: " + cleanExec)
if (typeof close === "function") close()
close()
}
onModeChanged: if (_isOpen) loadItems()
@@ -274,9 +274,7 @@ PanelWindow {
Keys.onReturnPressed: {
if (root.filteredItems.length > 0) {
let idx = resultsList.currentIndex;
if (idx === -1) idx = 0;
root.launch(root.filteredItems[idx]);
root.launch(root.filteredItems[Math.max(0, resultsList.currentIndex)])
}
}