notification popups

This commit is contained in:
end-4
2025-04-21 23:29:31 +02:00
parent 5dc0dc133d
commit 54fdf043c9
12 changed files with 240 additions and 46 deletions
+14 -1
View File
@@ -18,6 +18,8 @@ Singleton {
signal initDone();
signal notify(notification: var);
signal discard(id: var);
signal discardAll();
signal timeout(id: var);
NotificationServer {
id: notifServer
@@ -69,13 +71,24 @@ Singleton {
root.discard(id);
}
function discardAll() {
function discardAllNotifications() {
root.list = []
triggerListChange()
notifFileView.setText(JSON.stringify(root.list, null, 2))
notifServer.trackedNotifications.values.forEach((notif) => {
notif.dismiss()
})
root.discardAll();
}
function timeoutNotification(id) {
root.timeout(id);
}
function timeoutAll() {
root.list.forEach((notif) => {
root.timeout(notif.id);
})
}
function attemptInvokeAction(id, notifIdentifier) {