1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-06-23 11:35:25 -04:00

notifications: expireTimeout already comes in miliseconds

This commit is contained in:
bbedward
2026-06-22 15:03:49 -04:00
parent 5b28a63f75
commit 02ced4b87b
+2 -3
View File
@@ -771,11 +771,10 @@ Singleton {
interval: { interval: {
if (!wrapper.notification) if (!wrapper.notification)
return 5000; return 5000;
// Honor an app-specified expire timeout (seconds); -1 means the // expireTimeout is in milliseconds; -1 defers to our settings.
// app deferred to the server, so fall back to our per-urgency settings.
const appTimeout = wrapper.notification.expireTimeout; const appTimeout = wrapper.notification.expireTimeout;
if (appTimeout >= 0) if (appTimeout >= 0)
return Math.round(appTimeout * 1000); return Math.round(appTimeout);
switch (wrapper.urgency) { switch (wrapper.urgency) {
case NotificationUrgency.Low: case NotificationUrgency.Low:
return SettingsData.notificationTimeoutLow; return SettingsData.notificationTimeoutLow;