mirror of
https://github.com/vincentbernat/i3wm-configuration.git
synced 2025-07-25 21:34:43 +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
|
||||
notify=10
|
||||
|
||||
configure() {
|
||||
xset s $((timeout - notify)) $notify
|
||||
xset dpms $((timeout * 3)) $((timeout * 4)) $((timeout * 5))
|
||||
}
|
||||
|
||||
case "$1" in
|
||||
start)
|
||||
xset s $((timeout - notify)) $notify
|
||||
xset dpms $((timeout * 3)) $((timeout * 4)) $((timeout * 5))
|
||||
configure
|
||||
exec xss-lock -n "$me notify" -l $me lock
|
||||
;;
|
||||
dim|notify)
|
||||
|
@ -21,6 +25,8 @@ case "$1" in
|
|||
wait
|
||||
;;
|
||||
lock)
|
||||
# Something may have mendled with screensaver settings
|
||||
configure
|
||||
# First, stop any music player
|
||||
xdotool key XF86AudioStop
|
||||
# Then, lock screen
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue