change to using loaders

This commit is contained in:
Zacharias-Brohn
2025-11-12 13:16:01 +01:00
parent 01d22e582a
commit 14b01ad539
9 changed files with 350 additions and 208 deletions
+4 -14
View File
@@ -1,7 +1,7 @@
import QtQuick
import QtQuick.Layouts
import Quickshell.Io
import Quickshell.Hyprland
import qs.Helpers
Item {
id: root
@@ -12,22 +12,12 @@ Item {
property bool showFirst: true
Process {
id: initialTitleProc
command: ["./scripts/initialTitle.sh"]
running: false
stdout: StdioCollector {
onStreamFinished: {
let cleaned = this.text.trim().replace(/\"/g, "")
root.currentTitle = ( cleaned === "null" ) ? "" : cleaned
}
}
}
Component.onCompleted: {
Hyprland.rawEvent.connect(( event ) => {
if (event.name === "activewindow") {
initialTitleProc.running = true
InitialTitle.getInitialTitle( function( initialTitle ) {
root.currentTitle = initialTitle
})
}
})
}