renamed time to timemanager to be consistent

This commit is contained in:
2026-08-17 16:19:15 +01:00
parent e33041b66c
commit f90e62d25b
2 changed files with 1 additions and 1 deletions

49
Services/TimeManager.qml Normal file
View File

@@ -0,0 +1,49 @@
// Time.qml
// with this line our type becomes a Singleton
pragma Singleton
import QtQuick
import Quickshell
import Quickshell.Io
// your singletons should always have Singleton as the type
Singleton {
id: root
property string date
property string time
Process {
id: timeProc
command: ["date", "+%T"]
running: true
stdout: StdioCollector {
onStreamFinished: root.time = this.text
}
}
Process {
id: dateProc
command: ["date", "+%A %B %d %Y"]
running: true
stdout: StdioCollector {
onStreamFinished: root.date = this.text
}
}
Timer {
interval: 1000
repeat: true
running: true
onTriggered: {
timeProc.running = true;
dateProc.running = true;
}
}
}