diff options
author | 2012-08-21 20:15:43 -0700 | |
---|---|---|
committer | 2012-08-21 20:15:43 -0700 | |
commit | bf661bbab05eb9ecbfa7b3b9a82a7d41e795ed4a (patch) | |
tree | 767107659448fb6da349467476ef083de5b57f23 /java/src/com/android/inputmethod/latin/spellcheck/SpellCheckerProximityInfo.java | |
parent | 30904b2b4d45abbda8d19da3cc5f7228bfe2e4b5 (diff) | |
parent | eb59a87a074348d30191e57308221531ae613001 (diff) | |
download | latinime-bf661bbab05eb9ecbfa7b3b9a82a7d41e795ed4a.tar.gz latinime-bf661bbab05eb9ecbfa7b3b9a82a7d41e795ed4a.tar.xz latinime-bf661bbab05eb9ecbfa7b3b9a82a7d41e795ed4a.zip |
am eb59a87a: Merge "Add CollectionUtils class to create generic collection easily" into jb-mr1-dev
* commit 'eb59a87a074348d30191e57308221531ae613001':
Add CollectionUtils class to create generic collection easily
Diffstat (limited to 'java/src/com/android/inputmethod/latin/spellcheck/SpellCheckerProximityInfo.java')
-rw-r--r-- | java/src/com/android/inputmethod/latin/spellcheck/SpellCheckerProximityInfo.java | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/java/src/com/android/inputmethod/latin/spellcheck/SpellCheckerProximityInfo.java b/java/src/com/android/inputmethod/latin/spellcheck/SpellCheckerProximityInfo.java index 1762e29aa..fe5225ebd 100644 --- a/java/src/com/android/inputmethod/latin/spellcheck/SpellCheckerProximityInfo.java +++ b/java/src/com/android/inputmethod/latin/spellcheck/SpellCheckerProximityInfo.java @@ -17,6 +17,7 @@ package com.android.inputmethod.latin.spellcheck; import com.android.inputmethod.keyboard.ProximityInfo; +import com.android.inputmethod.latin.CollectionUtils; import com.android.inputmethod.latin.Constants; import java.util.TreeMap; @@ -59,7 +60,7 @@ public class SpellCheckerProximityInfo { // character. // Since we need to build such an array, we want to be able to search in our big proximity // data quickly by character, and a map is probably the best way to do this. - final private static TreeMap<Integer, Integer> INDICES = new TreeMap<Integer, Integer>(); + final private static TreeMap<Integer, Integer> INDICES = CollectionUtils.newTreeMap(); // The proximity here is the union of // - the proximity for a QWERTY keyboard. @@ -122,7 +123,7 @@ public class SpellCheckerProximityInfo { } private static class Cyrillic { - final private static TreeMap<Integer, Integer> INDICES = new TreeMap<Integer, Integer>(); + final private static TreeMap<Integer, Integer> INDICES = CollectionUtils.newTreeMap(); // TODO: The following table is solely based on the keyboard layout. Consult with Russian // speakers on commonly misspelled words/letters. final static int[] PROXIMITY = { |