From f084011a6115c4f157ca271b6cf69341aba91d2f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=BCllner?= Date: Thu, 16 Aug 2012 14:46:23 +0200 Subject: [PATCH] viewSelector: Make toggle-application-view binding available in overview https://bugzilla.gnome.org/show_bug.cgi?id=688202 --- js/ui/viewSelector.js | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/js/ui/viewSelector.js b/js/ui/viewSelector.js index bf06439e4..4d096ba49 100644 --- a/js/ui/viewSelector.js +++ b/js/ui/viewSelector.js @@ -144,15 +144,17 @@ const ViewSelector = new Lang.Class({ this.constrainHeight = new Clutter.BindConstraint({ source: this._pageArea, coordinate: Clutter.BindCoordinate.HEIGHT }); - global.display.add_keybinding('toggle-application-view', - new Gio.Settings({ schema: SHELL_KEYBINDINGS_SCHEMA }), - Meta.KeyBindingFlags.NONE, - Lang.bind(this, this._showWithAppsPage)); + Main.wm.addKeybinding('toggle-application-view', + new Gio.Settings({ schema: SHELL_KEYBINDINGS_SCHEMA }), + Meta.KeyBindingFlags.NONE, + Main.KeybindingMode.NORMAL | + Main.KeybindingMode.OVERVIEW, + Lang.bind(this, this._toggleAppsPage)); }, - _showWithAppsPage: function() { + _toggleAppsPage: function() { Main.overview.show(); - this._showAppsButton.set_checked(true); + this._showAppsButton.checked = !this._showAppsButton.checked; }, show: function() {