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

Unified Diff: content/browser/renderer_host/ime_adapter_android.cc

Issue 2309983002: Allow selection change update before beginBatchEdit (Closed)
Patch Set: polish up a bit Created 4 years, 3 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/browser/renderer_host/ime_adapter_android.cc
diff --git a/content/browser/renderer_host/ime_adapter_android.cc b/content/browser/renderer_host/ime_adapter_android.cc
index 98048d1b26f7ce91f37d69ed4443f1d9172fe5f6..770ed74d57d157a9dc847df5097ada4248e22456 100644
--- a/content/browser/renderer_host/ime_adapter_android.cc
+++ b/content/browser/renderer_host/ime_adapter_android.cc
@@ -289,6 +289,26 @@ bool ImeAdapterAndroid::RequestTextInputStateUpdate(
return true;
}
+bool ImeAdapterAndroid::BeginBatchEdit(
+ JNIEnv* env,
+ const JavaParamRef<jobject>&) {
+ RenderWidgetHostImpl* rwhi = GetRenderWidgetHostImpl();
+ if (!rwhi)
+ return false;
+ rwhi->Send(new InputMsg_ImeBatchEdit(rwhi->GetRoutingID(), true));
+ return true;
+}
+
+bool ImeAdapterAndroid::EndBatchEdit(
+ JNIEnv* env,
+ const JavaParamRef<jobject>&) {
+ RenderWidgetHostImpl* rwhi = GetRenderWidgetHostImpl();
+ if (!rwhi)
+ return false;
+ rwhi->Send(new InputMsg_ImeBatchEdit(rwhi->GetRoutingID(), false));
+ return true;
+}
+
void ImeAdapterAndroid::RequestCursorUpdate(
JNIEnv* env,
const base::android::JavaParamRef<jobject>& obj,

Powered by Google App Engine
This is Rietveld 408576698