emit resize event when banners are shown/hidden to restore scroll pos

This commit is contained in:
Bruno Windels 2019-03-12 17:29:16 +01:00
parent af0a51d3b2
commit 4795625cee
3 changed files with 34 additions and 10 deletions

View file

@ -220,7 +220,17 @@ const Notifier = {
}
},
isToolbarHidden: function() {
shouldShowToolbar: function() {
const client = MatrixClientPeg.get();
if (!client) {
return false;
}
const isGuest = client.isGuest();
return !isGuest && Notifier.supportsDesktopNotifications() &&
!Notifier.isEnabled() && !Notifier._isToolbarHidden();
},
_isToolbarHidden: function() {
// Check localStorage for any such meta data
if (global.localStorage) {
return global.localStorage.getItem("notifications_hidden") === "true";