aboutsummaryrefslogtreecommitdiffstats
path: root/java/src
diff options
context:
space:
mode:
authorJean Chalard <jchalard@google.com>2012-08-10 01:28:25 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2012-08-10 01:28:25 -0700
commit1599feda42e0f0881368b948222a0667a09de728 (patch)
treeb775fc250d6bb501764623cee4959299a32af2a3 /java/src
parent36e2a3bd49cf87fe07c2ec04942adde33dbe69bf (diff)
parentdc2fb6bc6d0c071b8023d62291becf2e2d59535c (diff)
downloadlatinime-1599feda42e0f0881368b948222a0667a09de728.tar.gz
latinime-1599feda42e0f0881368b948222a0667a09de728.tar.xz
latinime-1599feda42e0f0881368b948222a0667a09de728.zip
am dc2fb6bc: Merge "Pass the type from native code all the way to Java." into jb-mr1-dev
* commit 'dc2fb6bc6d0c071b8023d62291becf2e2d59535c': Pass the type from native code all the way to Java.
Diffstat (limited to 'java/src')
-rw-r--r--java/src/com/android/inputmethod/latin/BinaryDictionary.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/java/src/com/android/inputmethod/latin/BinaryDictionary.java b/java/src/com/android/inputmethod/latin/BinaryDictionary.java
index 7ba565c31..096764499 100644
--- a/java/src/com/android/inputmethod/latin/BinaryDictionary.java
+++ b/java/src/com/android/inputmethod/latin/BinaryDictionary.java
@@ -144,9 +144,10 @@ public class BinaryDictionary extends Dictionary {
++len;
}
if (len > 0) {
+ final int score = SuggestedWordInfo.KIND_WHITELIST == mOutputTypes[j]
+ ? SuggestedWordInfo.MAX_SCORE : mOutputScores[j];
suggestions.add(new SuggestedWordInfo(
- new String(mOutputChars, start, len),
- mOutputScores[j], SuggestedWordInfo.KIND_CORRECTION, mDictType));
+ new String(mOutputChars, start, len), score, mOutputTypes[j], mDictType));
}
}
return suggestions;