diff options
| author | Gregor Kleen <gkleen@yggdrasil.li> | 2025-09-15 21:36:45 +0200 |
|---|---|---|
| committer | Gregor Kleen <gkleen@yggdrasil.li> | 2025-09-15 21:36:45 +0200 |
| commit | 9d5fca89bb1a01f2b44979fac32ce97045f99381 (patch) | |
| tree | 896a19efc6b592582b1be34610eb32409bccde72 /accounts | |
| parent | 48a169afd72c63e8f7c0a896b51150c3e3db2ff3 (diff) | |
| download | nixos-9d5fca89bb1a01f2b44979fac32ce97045f99381.tar nixos-9d5fca89bb1a01f2b44979fac32ce97045f99381.tar.gz nixos-9d5fca89bb1a01f2b44979fac32ce97045f99381.tar.bz2 nixos-9d5fca89bb1a01f2b44979fac32ce97045f99381.tar.xz nixos-9d5fca89bb1a01f2b44979fac32ce97045f99381.zip | |
...
Diffstat (limited to 'accounts')
| -rw-r--r-- | accounts/gkleen@sif/shell/quickshell/Services/NotificationManager.qml | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/accounts/gkleen@sif/shell/quickshell/Services/NotificationManager.qml b/accounts/gkleen@sif/shell/quickshell/Services/NotificationManager.qml index c0e9458e..531d26c3 100644 --- a/accounts/gkleen@sif/shell/quickshell/Services/NotificationManager.qml +++ b/accounts/gkleen@sif/shell/quickshell/Services/NotificationManager.qml | |||
| @@ -58,6 +58,7 @@ Singleton { | |||
| 58 | { "test": { "appName": "Element" }, "group-by": [ "summary" ] } | 58 | { "test": { "appName": "Element" }, "group-by": [ "summary" ] } |
| 59 | ]; | 59 | ]; |
| 60 | 60 | ||
| 61 | property int historyLimit: 100 | ||
| 61 | property var history: [] | 62 | property var history: [] |
| 62 | 63 | ||
| 63 | Component { | 64 | Component { |
| @@ -147,6 +148,9 @@ Singleton { | |||
| 147 | } | 148 | } |
| 148 | 149 | ||
| 149 | function onNotificationClosed(notification, reason) { | 150 | function onNotificationClosed(notification, reason) { |
| 151 | while (root.history.length >= root.historyLimit) | ||
| 152 | root.history.shift(); | ||
| 153 | |||
| 150 | root.history.push({ | 154 | root.history.push({ |
| 151 | lock: notificationLock.createObject(root, { locked: true, object: notification }), | 155 | lock: notificationLock.createObject(root, { locked: true, object: notification }), |
| 152 | notification: notification | 156 | notification: notification |
