From 929e066506079600e483bf6a99061c5a48c9d1dd Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Wed, 17 Apr 2013 19:26:06 -0400 Subject: [PATCH] Add a toggle-overview keybinding This is a new, regular keybinding for going to the overview. The default binding is Super-S, which goes well with Super-A for going to the application grid. This is separate from the existing panel-main-menu keybinding, so that we can keep Alt-F1 opening the main menu in classic mode. https://bugzilla.gnome.org/show_bug.cgi?id=698251 --- data/50-gnome-shell-system.xml.in | 3 +++ data/org.gnome.shell.gschema.xml.in.in | 7 +++++++ js/ui/viewSelector.js | 8 ++++++++ 3 files changed, 18 insertions(+) diff --git a/data/50-gnome-shell-system.xml.in b/data/50-gnome-shell-system.xml.in index 92858c59d..3e8c6f847 100644 --- a/data/50-gnome-shell-system.xml.in +++ b/data/50-gnome-shell-system.xml.in @@ -11,6 +11,9 @@ + + diff --git a/data/org.gnome.shell.gschema.xml.in.in b/data/org.gnome.shell.gschema.xml.in.in index bacb6b1c8..7aae0ae46 100644 --- a/data/org.gnome.shell.gschema.xml.in.in +++ b/data/org.gnome.shell.gschema.xml.in.in @@ -117,6 +117,13 @@ value here is from the GsmPresenceStatus enumeration. Overview. + + ["<Super>s"] + <_summary>Keybinding to open the overview + <_description> + Keybinding to open the Activities Overview. + + ["<Super>m"] <_summary>Keybinding to toggle the visibility of the message tray diff --git a/js/ui/viewSelector.js b/js/ui/viewSelector.js index 0fd242de8..639acf30b 100644 --- a/js/ui/viewSelector.js +++ b/js/ui/viewSelector.js @@ -150,6 +150,14 @@ const ViewSelector = new Lang.Class({ Shell.KeyBindingMode.NORMAL | Shell.KeyBindingMode.OVERVIEW, Lang.bind(this, this._toggleAppsPage)); + + Main.wm.addKeybinding('toggle-overview', + new Gio.Settings({ schema: SHELL_KEYBINDINGS_SCHEMA }), + Meta.KeyBindingFlags.NONE, + Shell.KeyBindingMode.NORMAL | + Shell.KeyBindingMode.OVERVIEW, + Lang.bind(Main.overview, Main.overview.toggle)); + }, _toggleAppsPage: function() {