From fa12acb8b789081c532048ad03fcf8500cc6defb Mon Sep 17 00:00:00 2001 From: Jean Chalard Date: Thu, 1 Mar 2012 19:05:51 +0900 Subject: [PATCH] Change a dangerous ID The message id 0 is used intrinsically by the framework for all messages without a specific ID. Using 0 here we can't reliably use the post(Runnable) method on our handler, because these would in *some* respects be taken for update_suggestion messages, but not all. For example, they'd be removed on removeMessage() but they would not trigger the actual process. This would lead to utter confusion. Change-Id: I5d9b01d38e2ff090cd0d80c27421dc8a41c317b8 --- java/src/com/android/inputmethod/latin/LatinIME.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java index 47ec40f99..953d87beb 100644 --- a/java/src/com/android/inputmethod/latin/LatinIME.java +++ b/java/src/com/android/inputmethod/latin/LatinIME.java @@ -242,7 +242,6 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar public final UIHandler mHandler = new UIHandler(this); public static class UIHandler extends StaticInnerHandlerWrapper { - private static final int MSG_UPDATE_SUGGESTIONS = 0; private static final int MSG_UPDATE_SHIFT_STATE = 1; private static final int MSG_VOICE_RESULTS = 2; private static final int MSG_FADEOUT_LANGUAGE_ON_SPACEBAR = 3; @@ -250,6 +249,7 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar private static final int MSG_SPACE_TYPED = 5; private static final int MSG_SET_BIGRAM_PREDICTIONS = 6; private static final int MSG_PENDING_IMS_CALLBACK = 7; + private static final int MSG_UPDATE_SUGGESTIONS = 8; private int mDelayBeforeFadeoutLanguageOnSpacebar; private int mDelayUpdateSuggestions;