Chromium Code Reviews| Index: content/public/android/java/src/org/chromium/content/browser/input/ImeAdapter.java |
| diff --git a/content/public/android/java/src/org/chromium/content/browser/input/ImeAdapter.java b/content/public/android/java/src/org/chromium/content/browser/input/ImeAdapter.java |
| index c52b32457b7907883dd501925ab411e3f2c5b903..7d38b13cef3510ce90afc0536df548056c49a402 100644 |
| --- a/content/public/android/java/src/org/chromium/content/browser/input/ImeAdapter.java |
| +++ b/content/public/android/java/src/org/chromium/content/browser/input/ImeAdapter.java |
| @@ -193,7 +193,7 @@ public class ImeAdapter { |
| mLastSelectionStart, mLastSelectionEnd, outAttrs)); |
| if (DEBUG_LOGS) Log.w(TAG, "onCreateInputConnection: " + mInputConnection); |
| if (mCursorAnchorInfoController != null) { |
| - mCursorAnchorInfoController.resetMonitoringState(); |
| + onRequestCursorUpdates(0 /* disable any cursor update */); |
|
yosin_UTC9
2016/07/06 02:02:01
How about
const int kDisableAnyCursorUpdate = 0;
o
Seigo Nonaka
2016/07/06 03:25:56
Done.
|
| } |
| return mInputConnection; |
| } |
| @@ -661,6 +661,9 @@ public class ImeAdapter { |
| * Notified when IME requested Chrome to change the cursor update mode. |
| */ |
| public boolean onRequestCursorUpdates(int cursorUpdateMode) { |
| + if (mNativeImeAdapterAndroid != 0) { |
|
yosin_UTC9
2016/07/06 02:02:01
nit: Not need to have curly bracket.
Seigo Nonaka
2016/07/06 03:25:56
Thanks, but presubmit warns if I removed curly bra
|
| + nativeRequestCursorUpdate(mNativeImeAdapterAndroid, cursorUpdateMode); |
| + } |
| if (mCursorAnchorInfoController == null) return false; |
| return mCursorAnchorInfoController.onRequestCursorUpdates(cursorUpdateMode, |
| mViewEmbedder.getAttachedView()); |
| @@ -750,5 +753,6 @@ public class ImeAdapter { |
| int before, int after); |
| private native void nativeResetImeAdapter(long nativeImeAdapterAndroid); |
| private native boolean nativeRequestTextInputStateUpdate(long nativeImeAdapterAndroid); |
| + private native void nativeRequestCursorUpdate(long nativeImeAdapterAndroid, int mode); |
| private native boolean nativeIsImeThreadEnabled(long nativeImeAdapterAndroid); |
| } |