aboutsummaryrefslogtreecommitdiffstats
path: root/java/src
diff options
context:
space:
mode:
authorJean Chalard <jchalard@google.com>2012-06-28 17:04:12 +0900
committerJean Chalard <jchalard@google.com>2012-06-29 15:12:51 +0900
commit4d5e7235c566345a54121bfe5e53f58df1274352 (patch)
tree69286f67cdf94f43baebe08bd637978840139f46 /java/src
parent739683dcfb27c68b88eeacdfd486812321fc6b5a (diff)
downloadlatinime-4d5e7235c566345a54121bfe5e53f58df1274352.tar.gz
latinime-4d5e7235c566345a54121bfe5e53f58df1274352.tar.xz
latinime-4d5e7235c566345a54121bfe5e53f58df1274352.zip
Remove a useless variable (A20)
Change-Id: Ifc37462f5243563693c8cd7cbeb401ff054daa52
Diffstat (limited to 'java/src')
-rw-r--r--java/src/com/android/inputmethod/latin/Suggest.java10
1 files changed, 4 insertions, 6 deletions
diff --git a/java/src/com/android/inputmethod/latin/Suggest.java b/java/src/com/android/inputmethod/latin/Suggest.java
index bf3d9c45d..3a24c9f44 100644
--- a/java/src/com/android/inputmethod/latin/Suggest.java
+++ b/java/src/com/android/inputmethod/latin/Suggest.java
@@ -230,19 +230,17 @@ public class Suggest {
if (isCorrectionEnabled) {
final SuggestedWordInfo bestSuggestion = suggestionsSet.isEmpty()
? null : suggestionsSet.first();
- final CharSequence autoCorrection;
if (null != whitelistedWord) {
- autoCorrection = whitelistedWord;
+ hasAutoCorrection = true;
} else if (!AutoCorrection.isWhitelistedOrNotAWord(
mDictionaries, consideredWord, false)) {
- autoCorrection = consideredWord;
+ hasAutoCorrection = true;
} else if (AutoCorrection.hasAutoCorrectionForBinaryDictionary(bestSuggestion,
consideredWord, mAutoCorrectionThreshold)) {
- autoCorrection = bestSuggestion.mWord;
+ hasAutoCorrection = true;
} else {
- autoCorrection = null;
+ hasAutoCorrection = false;
}
- hasAutoCorrection = (null != autoCorrection);
} else {
hasAutoCorrection = false;
}