summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfalken@chromium.org <falken@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-06-11 07:46:32 +0000
committerfalken@chromium.org <falken@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-06-11 07:46:32 +0000
commit83852b1370893d934366f4c2a23bed7695ecce56 (patch)
tree67b976b3c313b505f9dec6e11f4fe9e2c3029a8c
parentfa7244d42bf5a6506efb4fe0e6eb45c007096b37 (diff)
downloadchromium_src-83852b1370893d934366f4c2a23bed7695ecce56.zip
chromium_src-83852b1370893d934366f4c2a23bed7695ecce56.tar.gz
chromium_src-83852b1370893d934366f4c2a23bed7695ecce56.tar.bz2
Don't cancel instant if renderer is clicked during IME composition.
This fixes the bug on Linux and Windows, but not on Mac. BUG=95397 TEST=enable instant. compose in an IME but don't commit, wait for instant to run, then click a link in the results. verify the link is navigated to as expected. Review URL: https://chromiumcodereview.appspot.com/10540046 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@141392 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/browser/autocomplete/autocomplete_edit.cc7
1 files changed, 6 insertions, 1 deletions
diff --git a/chrome/browser/autocomplete/autocomplete_edit.cc b/chrome/browser/autocomplete/autocomplete_edit.cc
index be0cf1f..9067077 100644
--- a/chrome/browser/autocomplete/autocomplete_edit.cc
+++ b/chrome/browser/autocomplete/autocomplete_edit.cc
@@ -1087,7 +1087,12 @@ bool AutocompleteEditModel::DoInstant(const AutocompleteMatch& match,
suggested_text);
}
- instant->Hide();
+ // It's possible DoInstant() was called due to an OnChanged() event from the
+ // omnibox view if the user clicked the renderer while IME composition was
+ // active. In that case we still want to commit on mouse up, so don't call
+ // Hide().
+ if (!instant->commit_on_mouse_up())
+ instant->Hide();
return false;
}