[gnome-shell] messageTray: Do not add the tray unconditionally to ctrl-alt-tab
- From: Florian MÃllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] messageTray: Do not add the tray unconditionally to ctrl-alt-tab
- Date: Thu, 11 Oct 2012 06:01:17 +0000 (UTC)
commit d2e830cce3cdb70e572292a840fa56be86d5533b
Author: Florian MÃllner <fmuellner gnome org>
Date: Wed Oct 10 22:17:39 2012 +0200
messageTray: Do not add the tray unconditionally to ctrl-alt-tab
Commit 448517032e5de87 added the message tray unconditionally to
the Ctrl-Alt-Tab popup, but while this makes sense for a normal
session, we do not want it in the login screen.
Be a bit more careful where we make the tray available.
https://bugzilla.gnome.org/show_bug.cgi?id=685914
js/ui/messageTray.js | 16 ++++++++++++----
1 files changed, 12 insertions(+), 4 deletions(-)
---
diff --git a/js/ui/messageTray.js b/js/ui/messageTray.js
index 982940a..30ce5cc 100644
--- a/js/ui/messageTray.js
+++ b/js/ui/messageTray.js
@@ -1514,7 +1514,7 @@ const MessageTray = new Lang.Class({
this._updateState();
}));
- Main.sessionMode.connect('updated', Lang.bind(this, this._updateState));
+ Main.sessionMode.connect('updated', Lang.bind(this, this._sessionUpdated));
global.display.add_keybinding('toggle-message-tray',
new Gio.Settings({ schema: SHELL_KEYBINDINGS_SCHEMA }),
@@ -1530,9 +1530,17 @@ const MessageTray = new Lang.Class({
this._trayDwelling = false;
this._trayDwellUserTime = 0;
- Main.ctrlAltTabManager.addGroup(this._summary, _("Message Tray"), 'start-here-symbolic',
- { focusCallback: Lang.bind(this, this.toggleAndNavigate),
- sortGroup: CtrlAltTab.SortGroup.BOTTOM });
+ this._sessionUpdated();
+ },
+
+ _sessionUpdated: function() {
+ if (Main.sessionMode.isLocked || Main.sessionMode.isGreeter)
+ Main.ctrlAltTabManager.removeGroup(this._summary);
+ else
+ Main.ctrlAltTabManager.addGroup(this._summary, _("Message Tray"), 'start-here-symbolic',
+ { focusCallback: Lang.bind(this, this.toggleAndNavigate),
+ sortGroup: CtrlAltTab.SortGroup.BOTTOM });
+ this._updateState();
},
_checkTrayDwell: function(x, y) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]