diff options
Diffstat (limited to 'java/src/com/android/inputmethod/latin/Suggest.java')
-rw-r--r-- | java/src/com/android/inputmethod/latin/Suggest.java | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/java/src/com/android/inputmethod/latin/Suggest.java b/java/src/com/android/inputmethod/latin/Suggest.java index f188b7ab1..5a4ddd960 100644 --- a/java/src/com/android/inputmethod/latin/Suggest.java +++ b/java/src/com/android/inputmethod/latin/Suggest.java @@ -83,7 +83,6 @@ public class Suggest implements Dictionary.WordCallback { private static final boolean DBG = LatinImeLogger.sDBG; - private AutoCorrection mAutoCorrection; private boolean mHasAutoCorrection; private Dictionary mMainDict; @@ -123,7 +122,6 @@ public class Suggest implements Dictionary.WordCallback { private void initWhitelistAndAutocorrectAndPool(final Context context, final Locale locale) { mWhiteListDictionary = new WhitelistDictionary(context, locale); addOrReplaceDictionary(mUnigramDictionaries, DICT_KEY_WHITELIST, mWhiteListDictionary); - mAutoCorrection = new AutoCorrection(); StringBuilderPool.ensureCapacity(mPrefMaxSuggestions, getApproxMaxWordLength()); } @@ -285,7 +283,6 @@ public class Suggest implements Dictionary.WordCallback { final WordComposer wordComposer, CharSequence prevWordForBigram, final ProximityInfo proximityInfo, final int correctionMode) { LatinImeLogger.onStartSuggestion(prevWordForBigram); - mAutoCorrection.init(); mIsFirstCharCapitalized = wordComposer.isFirstCharCapitalized(); mIsAllUpperCase = wordComposer.isAllUpperCase(); mTrailingSingleQuotesCount = wordComposer.trailingSingleQuotesCount(); @@ -366,7 +363,7 @@ public class Suggest implements Dictionary.WordCallback { mWhiteListDictionary.getWhitelistedWord(consideredWordString)); final CharSequence autoCorrection = - mAutoCorrection.updateAutoCorrectionStatus(mUnigramDictionaries, wordComposer, + AutoCorrection.computeAutoCorrectionWord(mUnigramDictionaries, wordComposer, mSuggestions, mScores, consideredWord, mAutoCorrectionThreshold, correctionMode, whitelistedWord); mHasAutoCorrection = (null != autoCorrection); |