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

Unified Diff: content/renderer/render_view_impl.cc

Issue 12093068: Adding missing UpdateTextInputState calls after each ime event. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Another attempt to fix testKeyboardDismissedAfterClickingGo Created 7 years, 10 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: content/renderer/render_view_impl.cc
diff --git a/content/renderer/render_view_impl.cc b/content/renderer/render_view_impl.cc
index 5867b191e79b118c9c66e1066e9047bd7a703a1b..b03f3c091b6c1b1e82c04ff89c18ead9e9e0043e 100644
--- a/content/renderer/render_view_impl.cc
+++ b/content/renderer/render_view_impl.cc
@@ -1450,7 +1450,10 @@ void RenderViewImpl::OnUnselect() {
}
void RenderViewImpl::OnSetEditableSelectionOffsets(int start, int end) {
+ handling_ime_event_ = true;
webview()->setEditableSelectionOffsets(start, end);
+ handling_ime_event_ = false;
+ UpdateTextInputState(DO_NOT_SHOW_IME);
}
void RenderViewImpl::OnSetCompositionFromExistingText(
@@ -1458,13 +1461,19 @@ void RenderViewImpl::OnSetCompositionFromExistingText(
const std::vector<WebKit::WebCompositionUnderline>& underlines) {
if (!webview())
return;
+ handling_ime_event_ = true;
webview()->setCompositionFromExistingText(start, end, underlines);
+ handling_ime_event_ = false;
+ UpdateTextInputState(DO_NOT_SHOW_IME);
}
void RenderViewImpl::OnExtendSelectionAndDelete(int before, int after) {
if (!webview())
return;
+ handling_ime_event_ = true;
webview()->extendSelectionAndDelete(before, after);
+ handling_ime_event_ = false;
+ UpdateTextInputState(DO_NOT_SHOW_IME);
}
void RenderViewImpl::OnSelectRange(const gfx::Point& start,

Powered by Google App Engine
This is Rietveld 408576698