mirror of
https://github.com/the-djmaze/snappymail.git
synced 2025-01-01 04:22:15 +08:00
More improvements for https://github.com/the-djmaze/snappymail/issues/37
This commit is contained in:
parent
b3b8c97b00
commit
cd52d9ae6c
3 changed files with 5 additions and 5 deletions
|
@ -95,7 +95,7 @@ class GeneralUserSettings {
|
|||
}
|
||||
|
||||
testSystemNotification() {
|
||||
NotificationStore.displayDesktopNotification('SnappyMail', 'Test notification', { 'Folder': '', 'Uid': '' });
|
||||
NotificationStore.displayDesktopNotification('SnappyMail', 'Test notification', { });
|
||||
}
|
||||
|
||||
onBuild() {
|
||||
|
|
|
@ -236,9 +236,7 @@ class MessageUserStore {
|
|||
initUidNextAndNewMessages(folder, uidNext, newMessages) {
|
||||
if (getFolderInboxName() === folder && uidNext) {
|
||||
if (Array.isNotEmpty(newMessages)) {
|
||||
newMessages.forEach(item => {
|
||||
addNewMessageCache(folder, item.Uid);
|
||||
});
|
||||
newMessages.forEach(item => addNewMessageCache(folder, item.Uid));
|
||||
|
||||
NotificationStore.playSoundNotification();
|
||||
|
||||
|
@ -249,7 +247,7 @@ class MessageUserStore {
|
|||
i18n('MESSAGE_LIST/NEW_MESSAGE_NOTIFICATION', {
|
||||
'COUNT': len
|
||||
}),
|
||||
{ 'Folder': '', 'Uid': '' }
|
||||
{ 'Url': mailBox(newMessages[0].Folder, 1) }
|
||||
);
|
||||
} else {
|
||||
newMessages.forEach(item => {
|
||||
|
|
|
@ -14,6 +14,8 @@ const HTML5Notification = window.Notification ? Notification : null,
|
|||
focus();
|
||||
if (data.Folder && data.Uid) {
|
||||
dispatchEvent(new CustomEvent('mailbox.message.show', {detail:data}));
|
||||
} else if (data.Url) {
|
||||
rl.route.setHash(data.Url);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue