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

Unified Diff: content/public/android/java/src/org/chromium/content/browser/input/ThreadedInputConnection.java

Issue 2464023002: Fix endBatchEdit
Patch Set: fix testBatchEdit_NoOp Created 4 years, 1 month 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/public/android/java/src/org/chromium/content/browser/input/ThreadedInputConnection.java
diff --git a/content/public/android/java/src/org/chromium/content/browser/input/ThreadedInputConnection.java b/content/public/android/java/src/org/chromium/content/browser/input/ThreadedInputConnection.java
index f7fb2f01ea37b58cdbca61ce507367a1c9900246..6040912c82e36df6a4850278bbd94d1bf0453bbf 100644
--- a/content/public/android/java/src/org/chromium/content/browser/input/ThreadedInputConnection.java
+++ b/content/public/android/java/src/org/chromium/content/browser/input/ThreadedInputConnection.java
@@ -115,7 +115,6 @@ public class ThreadedInputConnection extends BaseInputConnection
private final BlockingQueue<TextInputState> mQueue = new LinkedBlockingQueue<>();
private int mPendingAccent;
private TextInputState mCachedTextInputState;
- private boolean mLastInBatchEditMode;
ThreadedInputConnection(View view, ImeAdapter imeAdapter, Handler handler) {
super(view, true);
@@ -146,12 +145,8 @@ public class ThreadedInputConnection extends BaseInputConnection
if (DEBUG_LOGS) Log.w(TAG, "updateState: %s", mCachedTextInputState);
addToQueueOnUiThread(mCachedTextInputState);
- // If state update is caused by explicitly requesting the state update,
- // or batch edit just finished, then we may need to update state to IMM.
- if (isNonImeChange || (mLastInBatchEditMode && !inBatchEditMode)) {
- mHandler.post(mProcessPendingInputStatesRunnable);
- mLastInBatchEditMode = inBatchEditMode;
- }
+
+ if (isNonImeChange) mHandler.post(mProcessPendingInputStatesRunnable);
}
/**

Powered by Google App Engine
This is Rietveld 408576698