Allow closing of all pmgr notifications & remove on server disconnect

This commit is contained in:
Gina Häußge 2016-11-21 16:14:09 +01:00
parent 8034a4bb98
commit c9c2946db2

View file

@ -553,7 +553,7 @@ $(function() {
title: titleSuccess,
text: textRestart,
buttons: {
closer: false,
closer: true,
sticker: false
},
callbacks: {
@ -606,7 +606,7 @@ $(function() {
}]
},
buttons: {
closer: false,
closer: true,
sticker: false
},
callbacks: {
@ -698,6 +698,10 @@ $(function() {
};
self.onUserLoggedOut = function() {
self._closeAllNotifications();
};
self._closeAllNotifications = function() {
if (self.notifications) {
_.each(self.notifications, function(notification) {
notification.remove();
@ -705,6 +709,11 @@ $(function() {
}
};
self.onServerDisconnect = function() {
self._closeAllNotifications();
return true;
};
self.onStartup = function() {
self.workingDialog = $("#settings_plugin_pluginmanager_workingdialog");
self.workingOutput = $("#settings_plugin_pluginmanager_workingdialog_output");