From 7d6ae58e4f2f79605a046561f07aff9de1130057 Mon Sep 17 00:00:00 2001 From: Hadi Nategh Date: Tue, 3 Jul 2018 17:09:48 +0200 Subject: [PATCH] do not popup the next notification message if the one is getting deleted hasn't being expanded while deleting --- notifications/js/notificationajaxpopup.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/notifications/js/notificationajaxpopup.js b/notifications/js/notificationajaxpopup.js index 8904befc29..35d32c2bc3 100644 --- a/notifications/js/notificationajaxpopup.js +++ b/notifications/js/notificationajaxpopup.js @@ -525,15 +525,15 @@ request.sendRequest(true); var nextNode = egwpopup_message.next(); delete (notifymessages[id]); + if (nextNode.length > 0 && nextNode[0].id.match(/egwpopup_message_/ig) && egwpopup_message.hasClass('egwpopup_expanded')) + { + nextNode.trigger('click'); + } // try to close the dialog if expanded before hidding it this.collapseMessage(_node, _event); egwpopup_message.remove(); this.bell("inactive"); this.counterUpdate(); - if (nextNode.length > 0 && nextNode[0].id.match(/egwpopup_message_/ig)) - { - nextNode.trigger('click'); - } }; /**