1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-01-29 07:52:50 -05:00
This commit is contained in:
bbedward
2025-08-26 23:19:18 -04:00
parent 38b23d7fb0
commit 346e00d395
4 changed files with 45 additions and 31 deletions

View File

@@ -13,7 +13,6 @@ Singleton {
// Compositor detection
property bool isHyprland: false
property bool isNiri: false
property bool uwsmActive: false
property string compositor: "unknown"
readonly property string hyprlandSignature: Quickshell.env("HYPRLAND_INSTANCE_SIGNATURE")
@@ -81,7 +80,6 @@ Singleton {
Component.onCompleted: {
detectCompositor()
uwsmCheck.running = true
}
function filterCurrentWorkspace(toplevels, screen){
@@ -187,29 +185,4 @@ Singleton {
}
}
}
function logout() {
if (uwsmActive) {
Quickshell.execDetached(["uwsm", "stop"])
return
}
if (isNiri) {
NiriService.quit()
return
}
// Hyprland fallback
Hyprland.dispatch("exit")
}
Process {
id: uwsmCheck
// `uwsm check is-active` returns 0 if in uwsm-managed session, 1 otherwise
command: ["uwsm", "check", "is-active"]
running: false
onExited: function(exitCode) {
uwsmActive = exitCode === 0
}
}
}