Switch to suspend hook.
This commit is contained in:
parent
a1a2c6a3f2
commit
570daf6a1c
@ -1,6 +1,6 @@
|
|||||||
import os
|
import os
|
||||||
import subprocess
|
import subprocess
|
||||||
from libqtile import bar, extension, hook, layout
|
from libqtile import bar, extension, hook, layout, qtile
|
||||||
from libqtile.lazy import lazy
|
from libqtile.lazy import lazy
|
||||||
from libqtile.config import Click, Drag, DropDown, Group, Key, Match, ScratchPad, Screen
|
from libqtile.config import Click, Drag, DropDown, Group, Key, Match, ScratchPad, Screen
|
||||||
from libqtile.backend.wayland import InputConfig
|
from libqtile.backend.wayland import InputConfig
|
||||||
@ -25,10 +25,9 @@ def autostop():
|
|||||||
autostop = os.path.expanduser('~/.config/qtile/stop.sh')
|
autostop = os.path.expanduser('~/.config/qtile/stop.sh')
|
||||||
subprocess.Popen([autostop])
|
subprocess.Popen([autostop])
|
||||||
|
|
||||||
@hook.subscribe.resume
|
@hook.subscribe.suspend
|
||||||
def resume():
|
def suspend():
|
||||||
wallpaper = os.path.expanduser('~/.config/qtile/wallpaper.img')
|
qtile.spawn("swaylock --image ~/.config/qtile/wallpaper.img")
|
||||||
subprocess.Popen(['swaylock', '--image', wallpaper])
|
|
||||||
|
|
||||||
mod = "mod4"
|
mod = "mod4"
|
||||||
groups = [
|
groups = [
|
||||||
|
Loading…
Reference in New Issue
Block a user