From ec0fca8a8ba70c0d960838399e248db169d617d0 Mon Sep 17 00:00:00 2001 From: Jean Chalard Date: Thu, 8 Mar 2012 20:25:07 +0900 Subject: [PATCH] Remove useless stuff (A1) Remove an unused method and avoid doing a useless computation Change-Id: I29593c2e93f15857249b35bdd72ca28045056302 --- .../src/com/android/inputmethod/latin/AutoCorrection.java | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/java/src/com/android/inputmethod/latin/AutoCorrection.java b/java/src/com/android/inputmethod/latin/AutoCorrection.java index a9489da54..425b5c3f3 100644 --- a/java/src/com/android/inputmethod/latin/AutoCorrection.java +++ b/java/src/com/android/inputmethod/latin/AutoCorrection.java @@ -37,10 +37,6 @@ public class AutoCorrection { return null != mAutoCorrectionWord; } - public CharSequence getAutoCorrectionWord() { - return mAutoCorrectionWord; - } - public double getNormalizedScore() { return mNormalizedScore; } @@ -106,8 +102,8 @@ public class AutoCorrection { WordComposer wordComposer, ArrayList suggestions, CharSequence typedWord, int correctionMode) { if (TextUtils.isEmpty(typedWord)) return false; - boolean allowsAutoCorrect = allowsToBeAutoCorrected(dictionaries, typedWord, false); - return wordComposer.size() > 1 && suggestions.size() > 0 && !allowsAutoCorrect + return wordComposer.size() > 1 && suggestions.size() > 0 + && !allowsToBeAutoCorrected(dictionaries, typedWord, false) && (correctionMode == Suggest.CORRECTION_FULL || correctionMode == Suggest.CORRECTION_FULL_BIGRAM); }