lock screen: use quickshell, add hack for window refocus

This commit is contained in:
end-4
2025-08-09 08:56:12 +07:00
parent e15d2fe82c
commit fb4f8a86f4
2 changed files with 5 additions and 2 deletions
+2 -2
View File
@@ -1,5 +1,5 @@
# $lock_cmd = hyprctl dispatch global quickshell:lock & pidof qs quickshell hyprlock || hyprlock
$lock_cmd = pidof hyprlock || hyprlock
$lock_cmd = hyprctl dispatch global quickshell:lock & pidof qs quickshell hyprlock || hyprlock
# $lock_cmd = pidof hyprlock || hyprlock
$suspend_cmd = systemctl suspend || loginctl suspend
general {
@@ -19,6 +19,9 @@ Scope {
// Unlock the screen before exiting, or the compositor will display a
// fallback lock you can't interact with.
GlobalStates.screenLocked = false;
// Refocus last focused window on unlock (hack)
Quickshell.execDetached(["bash", "-c", `sleep 0.2; hyprctl --batch "dispatch togglespecialworkspace; dispatch togglespecialworkspace"`])
}
}