Notifications: Put actions inside onclick handler
This commit is contained in:
@@ -199,6 +199,7 @@ class NotificationService extends EventEmitter {
|
|||||||
tag: messageId,
|
tag: messageId,
|
||||||
});
|
});
|
||||||
|
|
||||||
|
notification.onclick = () => {
|
||||||
// Note: this maps to the xmlTemplate() function in app/WindowsNotifications.ts
|
// Note: this maps to the xmlTemplate() function in app/WindowsNotifications.ts
|
||||||
if (
|
if (
|
||||||
type === NotificationType.Message ||
|
type === NotificationType.Message ||
|
||||||
@@ -223,6 +224,8 @@ class NotificationService extends EventEmitter {
|
|||||||
} else {
|
} else {
|
||||||
throw missingCaseError(type);
|
throw missingCaseError(type);
|
||||||
}
|
}
|
||||||
|
};
|
||||||
|
|
||||||
this.lastNotification = notification;
|
this.lastNotification = notification;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user