aboutsummaryrefslogtreecommitdiffstats
path: root/java/src
diff options
context:
space:
mode:
authorKen Wakasa <kwakasa@google.com>2011-03-04 22:14:24 -0800
committerAndroid (Google) Code Review <android-gerrit@google.com>2011-03-04 22:14:24 -0800
commit5ac8546268a3c3cd2f523d086043d6200c553fa7 (patch)
tree5d5cbc0d1d1c8da8b92a8953258ec33f97cebd4e /java/src
parenta549101f3af5ece5bae8ebf0d3bf9976db0c8a4f (diff)
parentbaf263caf4681052fa627abe26efc9abfef40080 (diff)
downloadlatinime-5ac8546268a3c3cd2f523d086043d6200c553fa7.tar.gz
latinime-5ac8546268a3c3cd2f523d086043d6200c553fa7.tar.xz
latinime-5ac8546268a3c3cd2f523d086043d6200c553fa7.zip
Merge "Fix a NPE caused by a null typedWord" into honeycomb-mr1
Diffstat (limited to 'java/src')
-rw-r--r--java/src/com/android/inputmethod/latin/ExpandableDictionary.java2
-rw-r--r--java/src/com/android/inputmethod/latin/LatinIME.java1
2 files changed, 1 insertions, 2 deletions
diff --git a/java/src/com/android/inputmethod/latin/ExpandableDictionary.java b/java/src/com/android/inputmethod/latin/ExpandableDictionary.java
index b10e7a61e..b0bbe6d52 100644
--- a/java/src/com/android/inputmethod/latin/ExpandableDictionary.java
+++ b/java/src/com/android/inputmethod/latin/ExpandableDictionary.java
@@ -225,7 +225,7 @@ public class ExpandableDictionary extends Dictionary {
/**
* Returns the word's frequency or -1 if not found
*/
- public int getWordFrequency(CharSequence word) {
+ protected int getWordFrequency(CharSequence word) {
Node node = searchNode(mRoots, word, 0, word.length());
return (node == null) ? -1 : node.mFrequency;
}
diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java
index 646de66c2..c66cb5f26 100644
--- a/java/src/com/android/inputmethod/latin/LatinIME.java
+++ b/java/src/com/android/inputmethod/latin/LatinIME.java
@@ -1427,7 +1427,6 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
private void saveWordInHistory(CharSequence result) {
if (mWord.size() <= 1) {
- mWord.reset();
return;
}
// Skip if result is null. It happens in some edge case.