xss-lock: reconfigure X screensaver on lock

Some software seem to disable everything for some reason. Dunno who
this is.
This commit is contained in:
Vincent Bernat 2019-12-08 12:23:51 +01:00
parent ff62552a43
commit 9653179899

View file

@ -4,10 +4,14 @@ me="$(readlink -f "$0")"
timeout=300 timeout=300
notify=10 notify=10
case "$1" in configure() {
start)
xset s $((timeout - notify)) $notify xset s $((timeout - notify)) $notify
xset dpms $((timeout * 3)) $((timeout * 4)) $((timeout * 5)) xset dpms $((timeout * 3)) $((timeout * 4)) $((timeout * 5))
}
case "$1" in
start)
configure
exec xss-lock -n "$me notify" -l $me lock exec xss-lock -n "$me notify" -l $me lock
;; ;;
dim|notify) dim|notify)
@ -21,6 +25,8 @@ case "$1" in
wait wait
;; ;;
lock) lock)
# Something may have mendled with screensaver settings
configure
# First, stop any music player # First, stop any music player
xdotool key XF86AudioStop xdotool key XF86AudioStop
# Then, lock screen # Then, lock screen