mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-09-10 03:51:46 +02:00
fix: refine shoukei idle screen off
This commit is contained in:
@@ -18,14 +18,21 @@ listener {
|
||||
# the user had made those adjustments. niri (26.04) has no built-in idle timers,
|
||||
# so hypridle stays responsible for keyboard backlight, dpms and locking below.
|
||||
|
||||
# Some apps keep idle-inhibit active even when they are only sitting on a page,
|
||||
# which can prevent screen-off forever. Ignore those inhibitors for screen-off,
|
||||
# but skip the action while an MPRIS player reports active playback.
|
||||
listener {
|
||||
timeout = 900 # 15 minutes
|
||||
timeout = 360 # 6 minutes
|
||||
ignore_inhibit = true
|
||||
condition_cmd = ! playerctl -a status 2>/dev/null | grep -q '^Playing$'
|
||||
condition_retry = 30
|
||||
on-timeout = niri msg action power-off-monitors # DPMS off via niri
|
||||
on-resume = niri msg action power-on-monitors # DPMS on via niri
|
||||
}
|
||||
|
||||
listener {
|
||||
timeout = 1200 # 20 minutes
|
||||
ignore_inhibit = true
|
||||
on-timeout = noctalia-shell ipc call lockScreen lock # lock screen
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user