summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
authorkinuko@chromium.org <kinuko@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-07-02 02:43:40 +0000
committerkinuko@chromium.org <kinuko@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-07-02 02:43:40 +0000
commitd78628afc2dd18d9d1f5e04329d643b529ea158d (patch)
treebbe3ba121f9c45f27adcd7c60e4d05b9224840ac /chrome
parent956f9e8439f16ac65bb2689d7a5d36f5363b56bc (diff)
downloadchromium_src-d78628afc2dd18d9d1f5e04329d643b529ea158d.zip
chromium_src-d78628afc2dd18d9d1f5e04329d643b529ea158d.tar.gz
chromium_src-d78628afc2dd18d9d1f5e04329d643b529ea158d.tar.bz2
Revert 51480 - [Linux]When cancelling a composition, only focus out/in the IM context when it has focus.
BUG=http://crosbug.com/4449 TEST=See bug report. Review URL: http://codereview.chromium.org/2856028 TBR=suzhe@chromium.org Review URL: http://codereview.chromium.org/2848036 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@51481 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/renderer_host/gtk_im_context_wrapper.cc10
1 files changed, 4 insertions, 6 deletions
diff --git a/chrome/browser/renderer_host/gtk_im_context_wrapper.cc b/chrome/browser/renderer_host/gtk_im_context_wrapper.cc
index 8aa7f8c..35a6698 100644
--- a/chrome/browser/renderer_host/gtk_im_context_wrapper.cc
+++ b/chrome/browser/renderer_host/gtk_im_context_wrapper.cc
@@ -271,12 +271,10 @@ void GtkIMContextWrapper::CancelComposition() {
gtk_im_context_reset(context_);
gtk_im_context_reset(context_simple_);
- if (is_focused_) {
- // Some input methods may not honour the reset call. Focusing out/in the
- // |context_| to make sure it gets reset correctly.
- gtk_im_context_focus_out(context_);
- gtk_im_context_focus_in(context_);
- }
+ // Some input methods may not honour the reset call. Focusing out/in the
+ // |context_| to make sure it gets reset correctly.
+ gtk_im_context_focus_out(context_);
+ gtk_im_context_focus_in(context_);
is_composing_text_ = false;
preedit_text_.clear();