Mercurial > libervia-web
diff src/browser/libervia_main.py @ 714:03e9fe91081c
browser_side: use favico.js to display alerts counter
author | souliane <souliane@mailoo.org> |
---|---|
date | Mon, 20 Jul 2015 10:18:02 +0200 |
parents | 052d1d19016d |
children | 3b91225b457a |
line wrap: on
line diff
--- a/src/browser/libervia_main.py Wed Jul 15 13:34:17 2015 +0200 +++ b/src/browser/libervia_main.py Mon Jul 20 10:18:02 2015 +0200 @@ -86,6 +86,7 @@ RootPanel().add(self.panel) self.notification = notification.Notification() + self.alerts_counter = notification.FaviconCounter() DOM.addEventPreview(self) self.importPlugins() self._register = json.RegisterCall() @@ -642,6 +643,12 @@ def _newAlert(self, message, title, alert_type): dialog.InfoDialog(title, message).show() + def updateAlertsCounter(self): + """Update the over whole alerts counter + + """ + self.alerts_counter.update(self.alerts_count) + def _paramUpdate(self, name, value, category, refresh=True): """This is called when the paramUpdate signal is received, but also during initialization when the UI parameters values are retrieved.