diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java index 4328b823d7c6b20f816c442f82a1968d3524f2c2..8eeae86000ae5b8b6b20187063d3105d1a21cbd2 100644 --- a/java/src/com/android/inputmethod/latin/LatinIME.java +++ b/java/src/com/android/inputmethod/latin/LatinIME.java @@ -727,6 +727,14 @@ public class LatinIME extends InputMethodService if (mUserBigramDictionary != null) mUserBigramDictionary.flushPendingWrites(); } + @Override + public void onFinishInputView(boolean finishingInput) { + super.onFinishInputView(finishingInput); + // Remove penging messages related to update suggestions + mHandler.removeMessages(MSG_UPDATE_SUGGESTIONS); + mHandler.removeMessages(MSG_UPDATE_OLD_SUGGESTIONS); + } + @Override public void onUpdateExtractedText(int token, ExtractedText text) { super.onUpdateExtractedText(token, text);