setproctitle for hypridle support
This commit is contained in:
1 parent
1f9f25c2c4
commit
bb829c67f1
1 file changed
+5
-3
@@ -3,6 +3,7 @@ import gi, pam
|
|||||||
gi.require_version("Gdk", "3.0")
|
gi.require_version("Gdk", "3.0")
|
||||||
gi.require_version("Gtk", "3.0")
|
gi.require_version("Gtk", "3.0")
|
||||||
|
|
||||||
|
import setproctitle
|
||||||
|
|
||||||
gi.require_version("GtkSessionLock", "0.1")
|
gi.require_version("GtkSessionLock", "0.1")
|
||||||
from gi.repository import (
|
from gi.repository import (
|
||||||
@@ -57,7 +58,7 @@ class ContentBox(CenterBox):
|
|||||||
v_align="center",
|
v_align="center",
|
||||||
visible=False,
|
visible=False,
|
||||||
password=True,
|
password=True,
|
||||||
on_activate=on_activate,
|
# on_activate=on_activate,
|
||||||
)
|
)
|
||||||
|
|
||||||
self.password_entry.set_property("xalign", 0.5)
|
self.password_entry.set_property("xalign", 0.5)
|
||||||
@@ -138,7 +139,7 @@ class LockScreen(Window):
|
|||||||
self.content = ContentBox(self.on_activate)
|
self.content = ContentBox(self.on_activate)
|
||||||
super().__init__(
|
super().__init__(
|
||||||
title="lock",
|
title="lock",
|
||||||
visible=False,
|
visible=True,
|
||||||
all_visible=False,
|
all_visible=False,
|
||||||
name="lockscreen-bg",
|
name="lockscreen-bg",
|
||||||
anchor="center",
|
anchor="center",
|
||||||
@@ -212,7 +213,8 @@ def initialize():
|
|||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
initialize()
|
# initialize()
|
||||||
|
setproctitle.setproctitle("lockscreen")
|
||||||
lockscreen = LockScreen(GtkSessionLock.Lock())
|
lockscreen = LockScreen(GtkSessionLock.Lock())
|
||||||
|
|
||||||
app = Application("lock", lockscreen)
|
app = Application("lock", lockscreen)
|
||||||
|
|||||||
Reference in new issue
Block a user