diff options
| author | Syndamia <kamen.d.mladenov@protonmail.com> | 2021-09-03 12:45:25 +0300 |
|---|---|---|
| committer | Syndamia <kamen.d.mladenov@protonmail.com> | 2021-09-03 12:45:25 +0300 |
| commit | 0558f41dc24c0b8c9ae18ddf4d26eeede60f80a7 (patch) | |
| tree | 922e03ac48f9eabbd7a038c21f47d3d24ebfe063 | |
| parent | 8914da4bbc515fedaa2dc7c16aa3456262476c0e (diff) | |
| download | dotfiles-0558f41dc24c0b8c9ae18ddf4d26eeede60f80a7.tar dotfiles-0558f41dc24c0b8c9ae18ddf4d26eeede60f80a7.tar.gz dotfiles-0558f41dc24c0b8c9ae18ddf4d26eeede60f80a7.zip | |
(2) Removed automatic app launch on resolution change in autostart. And added app reset on login.
| -rw-r--r-- | .config/openbox/autostart | 9 | ||||
| -rwxr-xr-x | .i3lock/lock.sh | 12 |
2 files changed, 14 insertions, 7 deletions
diff --git a/.config/openbox/autostart b/.config/openbox/autostart index e7c51ff..86768da 100644 --- a/.config/openbox/autostart +++ b/.config/openbox/autostart @@ -2,12 +2,9 @@ # These commands are ran when an Openbox X Session is started. # -xhost +si:localuser:root # fixes unable to open display errors: https://askubuntu.com/a/1130413 -tail -n 1 -f /var/log/Xorg.0.log | while read # execute stuff when resolution (mostly) changes -do - ~/.fehbg & # wallpaper - lead & # hot corners, this is MageJohn's fork: https://github.com/MageJohn/lead -done & +xhost +si:localuser:root # fixes unable to open display errors: https://askubuntu.com/a/1130413 +~/.fehbg & # wallpaper +lead & # hot corners, this is MageJohn's fork: https://github.com/MageJohn/lead xcape -e 'Super_L=Super_L|P' & # used for the "windows" menu dunst & # notification daemon diff --git a/.i3lock/lock.sh b/.i3lock/lock.sh index 3ee73d6..406208f 100755 --- a/.i3lock/lock.sh +++ b/.i3lock/lock.sh @@ -1,5 +1,11 @@ #!/bin/bash +res () { + pkill $@ + nohup $@ 2>&1 & + disown +} + before_locking () { # Disables dunst, my notification daemon, so I don't see notification on lock screen # https://github.com/dunst-project/dunst/issues/697 @@ -9,6 +15,10 @@ before_locking () { when_unlocked () { dunstctl set-paused false # Enables my notification daemon + + # Resets programs, in case resolution changes + res ~/.fehbg # wallpaper + res lead # hot corners, this is MageJohn's fork: https://github.com/MageJohn/lead } when_unlocked_after_suspend () { @@ -18,7 +28,7 @@ when_unlocked_after_suspend () { # This makes sure to not lock the screen if audio is playing and there are no arguments given # It's mainly for preventing automatic screen locking while a video/music is playing # If you still want to lock, just give it some argument, doesn't matter what -if [ $(grep -r 'RUNNING' /proc/asound | wc -l) -lt 2 ] && [ $# -eq 0 ]; then +if [ $(grep -r 'RUNNING' /proc/asound | wc -l) -gt 0 ] && [ $# -eq 0 ]; then exit fi |
