mirror of
https://github.com/kossLAN/dots.git
synced 2025-11-05 06:59:50 -05:00
feat: init lockscreen
This commit is contained in:
parent
4687b955d4
commit
15ffd6d5b0
14 changed files with 433 additions and 4 deletions
41
lockscreen/Controller.qml
Normal file
41
lockscreen/Controller.qml
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
pragma ComponentBehavior: Bound
|
||||
|
||||
import Quickshell
|
||||
import Quickshell.Io
|
||||
import Quickshell.Wayland
|
||||
|
||||
Scope {
|
||||
id: root
|
||||
|
||||
PersistentProperties {
|
||||
id: persist
|
||||
property bool locked: false
|
||||
}
|
||||
|
||||
IpcHandler {
|
||||
target: "lockscreen"
|
||||
|
||||
function lock(): void {
|
||||
persist.locked = true;
|
||||
}
|
||||
}
|
||||
|
||||
LockContext {
|
||||
id: passwordContext
|
||||
|
||||
onUnlocked: persist.locked = false
|
||||
}
|
||||
|
||||
WlSessionLock {
|
||||
id: lock
|
||||
|
||||
locked: persist.locked
|
||||
|
||||
WlSessionLockSurface {
|
||||
LockSurface {
|
||||
anchors.fill: parent
|
||||
context: passwordContext
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue