summaryrefslogtreecommitdiff
path: root/accounts/gkleen@sif/shell/quickshell/Lockscreen.qml
diff options
context:
space:
mode:
Diffstat (limited to 'accounts/gkleen@sif/shell/quickshell/Lockscreen.qml')
-rw-r--r--accounts/gkleen@sif/shell/quickshell/Lockscreen.qml15
1 files changed, 14 insertions, 1 deletions
diff --git a/accounts/gkleen@sif/shell/quickshell/Lockscreen.qml b/accounts/gkleen@sif/shell/quickshell/Lockscreen.qml
index cc82a275..8e739359 100644
--- a/accounts/gkleen@sif/shell/quickshell/Lockscreen.qml
+++ b/accounts/gkleen@sif/shell/quickshell/Lockscreen.qml
@@ -2,6 +2,9 @@ import Quickshell
2import Quickshell.Wayland 2import Quickshell.Wayland
3import Quickshell.Io 3import Quickshell.Io
4import Quickshell.Services.Pam 4import Quickshell.Services.Pam
5import Quickshell.Services.Mpris
6import Custom as Custom
7import qs.Services
5import QtQml 8import QtQml
6 9
7Scope { 10Scope {
@@ -38,9 +41,19 @@ Scope {
38 WlSessionLock { 41 WlSessionLock {
39 id: lock 42 id: lock
40 43
41 onLockedChanged: { 44 onLockStateChanged: {
42 if (!locked && pam.active) 45 if (!locked && pam.active)
43 pam.abort(); 46 pam.abort();
47
48 if (locked) {
49 Custom.KeePassXC.lockAllDatabases();
50 Array.from(Mpris.players.values).forEach(player => {
51 if (player.canPause && player.isPlaying)
52 player.pause();
53 });
54 // Custom.Systemd.stopUserUnit("gpg-agent.service", "replace");
55 GpgAgent.reloadAgent();
56 }
44 } 57 }
45 58
46 WlSessionLockSurface { 59 WlSessionLockSurface {