Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(598)

Unified Diff: chrome/browser/chromeos/input_method/input_method_manager.cc

Issue 9852008: Update IME preferences outside the IME status button when Uber Tray is in use. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review Created 8 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chromeos/input_method/input_method_manager.cc
diff --git a/chrome/browser/chromeos/input_method/input_method_manager.cc b/chrome/browser/chromeos/input_method/input_method_manager.cc
index 031b9711824dd4cc756cd76d07d1c3a63b543f70..5bb546646e77cf0542bde978276255c8b2537a25 100644
--- a/chrome/browser/chromeos/input_method/input_method_manager.cc
+++ b/chrome/browser/chromeos/input_method/input_method_manager.cc
@@ -17,6 +17,7 @@
#include "base/string_util.h"
#include "base/stringprintf.h"
#include "chrome/browser/browser_process.h"
+#include "chrome/browser/chromeos/input_method/browser_state_monitor.h"
#include "chrome/browser/chromeos/input_method/input_method_util.h"
#include "chrome/browser/chromeos/input_method/input_method_whitelist.h"
#include "chrome/browser/chromeos/input_method/virtual_keyboard_selector.h"
@@ -83,6 +84,7 @@ class InputMethodManagerImpl : public InputMethodManager,
ibus_daemon_process_handle_(base::kNullProcessHandle),
util_(whitelist_.GetSupportedInputMethods()),
xkeyboard_(XKeyboard::Create(util_)),
+ ALLOW_THIS_IN_INITIALIZER_LIST(browser_state_monitor_(this)),
ignore_hotkeys_(false) {
// Observe APP_TERMINATING to stop input method daemon gracefully.
// We should not use APP_EXITING here since logout might be canceled by
@@ -1289,6 +1291,10 @@ class InputMethodManagerImpl : public InputMethodManager,
// auto-repeat interval.
scoped_ptr<XKeyboard> xkeyboard_;
+ // An object which monitors a notification from the browser to keep track of
+ // the browser state (not logged in, logged in, etc.).
+ BrowserStateMonitor browser_state_monitor_;
+
// true when DisableHotkeys() is called to temporarily disable IME hotkeys.
// EnableHotkeys() resets the flag to the default value, false.
bool ignore_hotkeys_;

Powered by Google App Engine
This is Rietveld 408576698