From 890a80902267befd30711770b8488072fcc8a9b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=BCllner?= Date: Thu, 26 Feb 2015 01:05:29 +0100 Subject: [PATCH] Drop MESSAGE_TRAY action mode The mode is never set after the removal of the bottom tray, so it no longer makes sense to pass it to allowKeybinding(). We can also safely remove it from the ActionModes flags altogether without requiring a synchronized update with gnome-settings-daemon, as the latter never used any flag value above LOGIN_SCREEN. --- js/ui/messageTray.js | 1 - js/ui/status/keyboard.js | 3 +-- src/shell-action-modes.h | 9 +++------ 3 files changed, 4 insertions(+), 9 deletions(-) diff --git a/js/ui/messageTray.js b/js/ui/messageTray.js index c66e7b9d2..149943c2f 100644 --- a/js/ui/messageTray.js +++ b/js/ui/messageTray.js @@ -1546,7 +1546,6 @@ const MessageTray = new Lang.Class({ new Gio.Settings({ schema_id: SHELL_KEYBINDINGS_SCHEMA }), Meta.KeyBindingFlags.NONE, Shell.ActionMode.NORMAL | - Shell.ActionMode.MESSAGE_TRAY | Shell.ActionMode.OVERVIEW, Lang.bind(this, this._expandActiveNotification)); diff --git a/js/ui/status/keyboard.js b/js/ui/status/keyboard.js index 6e9965843..317955439 100644 --- a/js/ui/status/keyboard.js +++ b/js/ui/status/keyboard.js @@ -242,8 +242,7 @@ const InputSourceManager = new Lang.Class({ // effect without considerable work to consolidate the usage // of pushModal/popModal and grabHelper. See // https://bugzilla.gnome.org/show_bug.cgi?id=695143 . - if (Main.actionMode == Shell.ActionMode.MESSAGE_TRAY || - Main.actionMode == Shell.ActionMode.POPUP) { + if (Main.actionMode == Shell.ActionMode.POPUP) { this._modifiersSwitcher(); return; } diff --git a/src/shell-action-modes.h b/src/shell-action-modes.h index bf21d341c..a6f4718b1 100644 --- a/src/shell-action-modes.h +++ b/src/shell-action-modes.h @@ -10,8 +10,6 @@ * @SHELL_ACTION_MODE_UNLOCK_SCREEN: allow action in the unlock * dialog * @SHELL_ACTION_MODE_LOGIN_SCREEN: allow action in the login screen - * @SHELL_ACTION_MODE_MESSAGE_TRAY: allow action while the message - * tray is popped up * @SHELL_ACTION_MODE_SYSTEM_MODAL: allow action when a system modal * dialog (e.g. authentification or session dialogs) is open * @SHELL_ACTION_MODE_LOOKING_GLASS: allow action in looking glass @@ -28,10 +26,9 @@ typedef enum { SHELL_ACTION_MODE_LOCK_SCREEN = 1 << 2, SHELL_ACTION_MODE_UNLOCK_SCREEN = 1 << 3, SHELL_ACTION_MODE_LOGIN_SCREEN = 1 << 4, - SHELL_ACTION_MODE_MESSAGE_TRAY = 1 << 5, - SHELL_ACTION_MODE_SYSTEM_MODAL = 1 << 6, - SHELL_ACTION_MODE_LOOKING_GLASS = 1 << 7, - SHELL_ACTION_MODE_POPUP = 1 << 8, + SHELL_ACTION_MODE_SYSTEM_MODAL = 1 << 5, + SHELL_ACTION_MODE_LOOKING_GLASS = 1 << 6, + SHELL_ACTION_MODE_POPUP = 1 << 7, SHELL_ACTION_MODE_ALL = ~0, } ShellActionMode;