diff options
author | yusukes@chromium.org <yusukes@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-09-07 07:24:06 +0000 |
---|---|---|
committer | yusukes@chromium.org <yusukes@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-09-07 07:24:06 +0000 |
commit | 41a0ab5c11be2b6bb29849426efb1d7af4cae866 (patch) | |
tree | f8d6a3458df68abd120dbf397a59529938e6e05f | |
parent | a16f24f68a44bc33c069a8c89bf9a87c3823b343 (diff) | |
download | chromium_src-41a0ab5c11be2b6bb29849426efb1d7af4cae866.zip chromium_src-41a0ab5c11be2b6bb29849426efb1d7af4cae866.tar.gz chromium_src-41a0ab5c11be2b6bb29849426efb1d7af4cae866.tar.bz2 |
Call SetCurrentKeyboardLayoutByName("us") instead of ChangeInputMethod("xkb:us::eng") in StopInputMethodProcesses.
BUG=chromium-os:6461
TEST=manually
Review URL: http://codereview.chromium.org/3342018
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@58672 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | chrome/browser/chromeos/cros/input_method_library.cc | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/chrome/browser/chromeos/cros/input_method_library.cc b/chrome/browser/chromeos/cros/input_method_library.cc index 64eaece..99823ee 100644 --- a/chrome/browser/chromeos/cros/input_method_library.cc +++ b/chrome/browser/chromeos/cros/input_method_library.cc @@ -15,6 +15,7 @@ #include "chrome/browser/chrome_thread.h" #include "chrome/browser/chromeos/cros/cros_library.h" #include "chrome/browser/chromeos/cros/keyboard_library.h" +#include "chrome/browser/chromeos/input_method/input_method_util.h" #include "chrome/browser/chromeos/language_preferences.h" namespace { @@ -452,9 +453,13 @@ class InputMethodLibraryImpl : public InputMethodLibrary { void StopInputMethodProcesses() { ime_running_ = false; if (ime_handle_) { - chromeos::ChangeInputMethod( - input_method_status_connection_, - chromeos::GetHardwareKeyboardLayoutName().c_str()); + const std::string xkb_engine_name = + chromeos::GetHardwareKeyboardLayoutName(); + // We should not use chromeos::ChangeInputMethod() here since without the + // ibus-daemon process, UpdateCurrentInputMethod() callback function which + // actually changes the XKB layout will not be called. + CrosLibrary::Get()->GetKeyboardLibrary()->SetCurrentKeyboardLayoutByName( + chromeos::input_method::GetKeyboardLayoutName(xkb_engine_name)); kill(ime_handle_, SIGTERM); ime_handle_ = 0; } |