mirror of
https://github.com/vincentbernat/i3wm-configuration.git
synced 2025-07-27 06:14:45 +02:00
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:
parent
ff62552a43
commit
9653179899
1 changed files with 8 additions and 2 deletions
10
bin/xss-lock
10
bin/xss-lock
|
@ -4,10 +4,14 @@ me="$(readlink -f "$0")"
|
||||||
timeout=300
|
timeout=300
|
||||||
notify=10
|
notify=10
|
||||||
|
|
||||||
|
configure() {
|
||||||
|
xset s $((timeout - notify)) $notify
|
||||||
|
xset dpms $((timeout * 3)) $((timeout * 4)) $((timeout * 5))
|
||||||
|
}
|
||||||
|
|
||||||
case "$1" in
|
case "$1" in
|
||||||
start)
|
start)
|
||||||
xset s $((timeout - notify)) $notify
|
configure
|
||||||
xset dpms $((timeout * 3)) $((timeout * 4)) $((timeout * 5))
|
|
||||||
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
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue