diff options
author | 2011-10-12 23:44:54 -0700 | |
---|---|---|
committer | 2011-10-12 23:44:54 -0700 | |
commit | 605a6fea750c4acc96a5136ecaf7162e0a858b9f (patch) | |
tree | ce110e0665dda3f5a32998361b498f6b00b2380d /java/src/com/android/inputmethod/latin/LatinIME.java | |
parent | 8a4472f0ecd774757c7077a40585f2d05e4f9210 (diff) | |
parent | 2aa1dd45c44295e2f7e8ece1b520032d86b9f908 (diff) | |
download | latinime-605a6fea750c4acc96a5136ecaf7162e0a858b9f.tar.gz latinime-605a6fea750c4acc96a5136ecaf7162e0a858b9f.tar.xz latinime-605a6fea750c4acc96a5136ecaf7162e0a858b9f.zip |
Merge "Fix the safety net Bug: 5453150" into ics-mr0
Diffstat (limited to 'java/src/com/android/inputmethod/latin/LatinIME.java')
-rw-r--r-- | java/src/com/android/inputmethod/latin/LatinIME.java | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java index 2c4b34f4d..ec8dcc9b9 100644 --- a/java/src/com/android/inputmethod/latin/LatinIME.java +++ b/java/src/com/android/inputmethod/latin/LatinIME.java @@ -1729,9 +1729,14 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar } public void showSuggestions(SuggestedWords suggestedWords, CharSequence typedWord) { + final boolean shouldBlockAutoCorrectionBySafetyNet = + Utils.shouldBlockAutoCorrectionBySafetyNet(suggestedWords, mSuggest); + if (shouldBlockAutoCorrectionBySafetyNet) { + suggestedWords.setShouldBlockAutoCorrection(); + } setSuggestions(suggestedWords); if (suggestedWords.size() > 0) { - if (Utils.shouldBlockedBySafetyNetForAutoCorrection(suggestedWords, mSuggest)) { + if (shouldBlockAutoCorrectionBySafetyNet) { mBestWord = typedWord; } else if (suggestedWords.hasAutoCorrectionWord()) { mBestWord = suggestedWords.getWord(1); |