Simulate a focus-app change when leaving the overview

When the currently focused app sends a notification while in the overview,
the corresponding source icon is not removed when the overview is left.
It does make some sense to treat the overview transition the same as a
normal focus change, so we should update the summary view accordingly.
This commit is contained in:
Florian Müllner 2010-02-24 21:46:00 +01:00
parent edbfafc5bd
commit ff01bf68fd

View File

@ -103,6 +103,8 @@ NotificationDaemon.prototype = {
Shell.WindowTracker.get_default().connect('notify::focus-app', Shell.WindowTracker.get_default().connect('notify::focus-app',
Lang.bind(this, this._onFocusAppChanged)); Lang.bind(this, this._onFocusAppChanged));
Main.overview.connect('hidden',
Lang.bind(this, this._onFocusAppChanged));
}, },
_acquiredName: function() { _acquiredName: function() {
@ -263,7 +265,8 @@ NotificationDaemon.prototype = {
]; ];
}, },
_onFocusAppChanged: function(tracker) { _onFocusAppChanged: function() {
let tracker = Shell.WindowTracker.get_default();
Main.messageTray.removeSourceByApp(tracker.focus_app); Main.messageTray.removeSourceByApp(tracker.focus_app);
}, },