aboutsummaryrefslogtreecommitdiffstats
path: root/java/src/com/android/inputmethod/latin/LatinIME.java
diff options
context:
space:
mode:
authorSatoshi Kataoka <satok@google.com>2012-11-30 19:29:48 +0900
committerSatoshi Kataoka <satok@google.com>2012-11-30 19:29:48 +0900
commite5d8dc958af5dc4b20f7103052dcda16abc11d8c (patch)
tree8c417c1111941f1da48fa7ed5d04049f5d1a879d /java/src/com/android/inputmethod/latin/LatinIME.java
parent83b288722b2509cb286f9dfa999b3e1a6eade95f (diff)
parent16e9d343c4ab0d4260f9baaabf13593f8946368f (diff)
downloadlatinime-e5d8dc958af5dc4b20f7103052dcda16abc11d8c.tar.gz
latinime-e5d8dc958af5dc4b20f7103052dcda16abc11d8c.tar.xz
latinime-e5d8dc958af5dc4b20f7103052dcda16abc11d8c.zip
Merge remote-tracking branch 'goog/master' into mergescriptpackage
Diffstat (limited to 'java/src/com/android/inputmethod/latin/LatinIME.java')
-rw-r--r--java/src/com/android/inputmethod/latin/LatinIME.java7
1 files changed, 4 insertions, 3 deletions
diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java
index 0b49659e3..8519ad31d 100644
--- a/java/src/com/android/inputmethod/latin/LatinIME.java
+++ b/java/src/com/android/inputmethod/latin/LatinIME.java
@@ -1464,7 +1464,7 @@ public final class LatinIME extends InputMethodService implements KeyboardAction
private static final class BatchInputUpdater implements Handler.Callback {
private final Handler mHandler;
private LatinIME mLatinIme;
- private boolean mInBatchInput; // synchornized using "this".
+ private boolean mInBatchInput; // synchronized using "this".
private BatchInputUpdater() {
final HandlerThread handlerThread = new HandlerThread(
@@ -1496,6 +1496,7 @@ public final class LatinIME extends InputMethodService implements KeyboardAction
// Run in the UI thread.
public synchronized void onStartBatchInput() {
+ mHandler.removeMessages(MSG_UPDATE_GESTURE_PREVIEW_AND_SUGGESTION_STRIP);
mInBatchInput = true;
}
@@ -1503,7 +1504,7 @@ public final class LatinIME extends InputMethodService implements KeyboardAction
private synchronized void updateBatchInput(final InputPointers batchPointers,
final LatinIME latinIme) {
if (!mInBatchInput) {
- // Batch input has ended while the message was being delivered.
+ // Batch input has ended or canceled while the message was being delivered.
return;
}
final SuggestedWords suggestedWords = getSuggestedWordsGestureLocked(
@@ -1523,7 +1524,7 @@ public final class LatinIME extends InputMethodService implements KeyboardAction
.sendToTarget();
}
- public void onCancelBatchInput(final LatinIME latinIme) {
+ public synchronized void onCancelBatchInput(final LatinIME latinIme) {
mInBatchInput = false;
latinIme.mHandler.showGesturePreviewAndSuggestionStrip(
SuggestedWords.EMPTY, true /* dismissGestureFloatingPreviewText */);