diff options
author | 2011-01-19 01:05:39 -0800 | |
---|---|---|
committer | 2011-01-19 01:05:39 -0800 | |
commit | 1e6d39104814083011d556376974f241e51a8bed (patch) | |
tree | 77d28d5c4c37f246d329c2e2f5ca033e43cafd11 /java/src/com/android/inputmethod/latin/LatinIME.java | |
parent | 53746972d0dda9cbbf3d49cfa71271eaeb5cfe5b (diff) | |
parent | ce4b2d2daba8005c2c07a995c8a145ee812f56ff (diff) | |
download | latinime-1e6d39104814083011d556376974f241e51a8bed.tar.gz latinime-1e6d39104814083011d556376974f241e51a8bed.tar.xz latinime-1e6d39104814083011d556376974f241e51a8bed.zip |
am ce4b2d2d: Merge "Add a safety net for auto-correction." into honeycomb
* commit 'ce4b2d2daba8005c2c07a995c8a145ee812f56ff':
Add a safety net for auto-correction.
Diffstat (limited to 'java/src/com/android/inputmethod/latin/LatinIME.java')
-rw-r--r-- | java/src/com/android/inputmethod/latin/LatinIME.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java index 5d48d6b36..fff09fa97 100644 --- a/java/src/com/android/inputmethod/latin/LatinIME.java +++ b/java/src/com/android/inputmethod/latin/LatinIME.java @@ -1537,7 +1537,9 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen private void showSuggestions(SuggestedWords suggestedWords, CharSequence typedWord) { setSuggestions(suggestedWords); if (suggestedWords.size() > 0) { - if (suggestedWords.hasAutoCorrectionWord()) { + if (Utils.shouldBlockedBySafetyNetForAutoCorrection(suggestedWords)) { + mBestWord = typedWord; + } else if (suggestedWords.hasAutoCorrectionWord()) { mBestWord = suggestedWords.getWord(1); } else { mBestWord = typedWord; |