diff options
author | 2012-06-26 18:41:02 +0900 | |
---|---|---|
committer | 2012-06-26 18:42:06 +0900 | |
commit | 6cad198d9c02646d6bab9ec683f99680b111c659 (patch) | |
tree | 9e4c1f1a2b74f9a320abe0a0322065253865b3e2 /java/src | |
parent | 0da9a7c094ed29f680f1ab9d4a27194a84c593c3 (diff) | |
download | latinime-6cad198d9c02646d6bab9ec683f99680b111c659.tar.gz latinime-6cad198d9c02646d6bab9ec683f99680b111c659.tar.xz latinime-6cad198d9c02646d6bab9ec683f99680b111c659.zip |
Remove a useless member (A2)
Change-Id: Ia727ffc2946352bbf79e0c97684f8fa98f428cef
Diffstat (limited to 'java/src')
-rw-r--r-- | java/src/com/android/inputmethod/latin/Suggest.java | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/java/src/com/android/inputmethod/latin/Suggest.java b/java/src/com/android/inputmethod/latin/Suggest.java index 6f7a23a15..26dbe5773 100644 --- a/java/src/com/android/inputmethod/latin/Suggest.java +++ b/java/src/com/android/inputmethod/latin/Suggest.java @@ -86,8 +86,6 @@ public class Suggest { private float mAutoCorrectionThreshold; - private CharSequence mConsideredWord; - // TODO: Remove these member variables by passing more context to addWord() callback method private boolean mIsFirstCharCapitalized; private boolean mIsAllUpperCase; @@ -228,7 +226,6 @@ public class Suggest { : typedWord; // Treating USER_TYPED as UNIGRAM suggestion for logging now. LatinImeLogger.onAddSuggestedWord(typedWord, Suggest.DIC_USER_TYPED, Dictionary.UNIGRAM); - mConsideredWord = consideredWord; if (wordComposer.size() <= 1 && isCorrectionEnabled) { // At first character typed, search only the bigrams @@ -251,7 +248,8 @@ public class Suggest { for (final SuggestedWordInfo suggestion : localSuggestions) { final String suggestionStr = suggestion.mWord.toString(); addWord(suggestionStr.toCharArray(), null, 0, suggestionStr.length(), - suggestion.mScore, dicTypeId, Dictionary.BIGRAM, suggestions); + suggestion.mScore, dicTypeId, Dictionary.BIGRAM, + suggestions, consideredWord); } } } @@ -277,7 +275,8 @@ public class Suggest { for (final SuggestedWordInfo suggestion : localSuggestions) { final String suggestionStr = suggestion.mWord.toString(); addWord(suggestionStr.toCharArray(), null, 0, suggestionStr.length(), - suggestion.mScore, dicTypeId, Dictionary.UNIGRAM, suggestions); + suggestion.mScore, dicTypeId, Dictionary.UNIGRAM, + suggestions, consideredWord); } } } @@ -387,14 +386,14 @@ public class Suggest { // TODO: Use codepoint instead of char public boolean addWord(final char[] word, int[] indices, final int offset, final int length, int score, final int dicTypeId, final int dataType, - final ArrayList<SuggestedWordInfo> suggestions) { + final ArrayList<SuggestedWordInfo> suggestions, final String consideredWord) { int dataTypeForLog = dataType; final int prefMaxSuggestions = MAX_SUGGESTIONS; int pos = 0; // Check if it's the same word, only caps are different - if (StringUtils.equalsIgnoreCase(mConsideredWord, word, offset, length)) { + if (StringUtils.equalsIgnoreCase(consideredWord, word, offset, length)) { // TODO: remove this surrounding if clause and move this logic to // getSuggestedWordBuilder. if (suggestions.size() > 0) { |