[gnome-shell/wip/message-tray: 13/23] messageTray: Grab the key focus when entering from the keybinding
- From: Marina Zhurakhinskaya <marinaz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/message-tray: 13/23] messageTray: Grab the key focus when entering from the keybinding
- Date: Sun, 19 Aug 2012 21:18:10 +0000 (UTC)
commit 8c86f2078ed1a0e9f11a405379695aaf03347982
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Wed Aug 15 13:42:31 2012 -0400
messageTray: Grab the key focus when entering from the keybinding
js/ui/messageTray.js | 9 ++++++++-
1 files changed, 8 insertions(+), 1 deletions(-)
---
diff --git a/js/ui/messageTray.js b/js/ui/messageTray.js
index 73d41ce..493f6c3 100644
--- a/js/ui/messageTray.js
+++ b/js/ui/messageTray.js
@@ -1423,7 +1423,7 @@ const MessageTray = new Lang.Class({
global.display.add_keybinding('toggle-message-tray',
new Gio.Settings({ schema: SHELL_KEYBINDINGS_SCHEMA }),
Meta.KeyBindingFlags.NONE,
- Lang.bind(this, this.toggle));
+ Lang.bind(this, this.toggleAndNavigate));
this._summaryItems = [];
this._chatSummaryItemsCount = 0;
@@ -1575,6 +1575,13 @@ const MessageTray = new Lang.Class({
this._updateState();
},
+ toggleAndNavigate: function() {
+ // Grab the key focus so that GrabHelper knows
+ // that we have the key grab.
+ this._summary.grab_key_focus();
+ this.toggle();
+ },
+
hide: function() {
this._traySummoned = false;
this.actor.set_hover(false);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]