diff options
author | 2012-06-04 19:57:42 -0700 | |
---|---|---|
committer | 2012-06-04 19:57:42 -0700 | |
commit | 9252fc1b88df0c8bd3870546d1c8ca7681e435d3 (patch) | |
tree | 604c3a03f64caee19a808611f4d15b2200d0b516 /java/src/com/android/inputmethod/latin/spellcheck/AndroidSpellCheckerService.java | |
parent | 89b5872a88ed8e0623263957a0c4b25c5d4a5b69 (diff) | |
parent | dd4872474a8dacf410b9b4810a8d82adcd995dff (diff) | |
download | latinime-9252fc1b88df0c8bd3870546d1c8ca7681e435d3.tar.gz latinime-9252fc1b88df0c8bd3870546d1c8ca7681e435d3.tar.xz latinime-9252fc1b88df0c8bd3870546d1c8ca7681e435d3.zip |
am dd487247: Merge "Read the script correctly" into jb-dev
* commit 'dd4872474a8dacf410b9b4810a8d82adcd995dff':
Read the script correctly
Diffstat (limited to 'java/src/com/android/inputmethod/latin/spellcheck/AndroidSpellCheckerService.java')
-rw-r--r-- | java/src/com/android/inputmethod/latin/spellcheck/AndroidSpellCheckerService.java | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/java/src/com/android/inputmethod/latin/spellcheck/AndroidSpellCheckerService.java b/java/src/com/android/inputmethod/latin/spellcheck/AndroidSpellCheckerService.java index 0e3bf8011..ede788d6e 100644 --- a/java/src/com/android/inputmethod/latin/spellcheck/AndroidSpellCheckerService.java +++ b/java/src/com/android/inputmethod/latin/spellcheck/AndroidSpellCheckerService.java @@ -99,11 +99,13 @@ public class AndroidSpellCheckerService extends SpellCheckerService // List of the supported languages and their associated script. We won't check // words written in another script than the selected script, because we know we // don't have those in our dictionary so we will underline everything and we - // will never have any suggestions, so it makes no sense checking them. + // will never have any suggestions, so it makes no sense checking them, and this + // is done in {@link #shouldFilterOut}. Also, the script is used to choose which + // proximity to pass to the dictionary descent algorithm. + // IMPORTANT: this only contains languages - do not write countries in there. + // Only the language is searched from the map. mLanguageToScript = new TreeMap<String, Integer>(); mLanguageToScript.put("en", SCRIPT_LATIN); - mLanguageToScript.put("en_US", SCRIPT_LATIN); - mLanguageToScript.put("en_GB", SCRIPT_LATIN); mLanguageToScript.put("fr", SCRIPT_LATIN); mLanguageToScript.put("de", SCRIPT_LATIN); mLanguageToScript.put("nl", SCRIPT_LATIN); @@ -111,7 +113,7 @@ public class AndroidSpellCheckerService extends SpellCheckerService mLanguageToScript.put("es", SCRIPT_LATIN); mLanguageToScript.put("it", SCRIPT_LATIN); mLanguageToScript.put("hr", SCRIPT_LATIN); - mLanguageToScript.put("pt_BR", SCRIPT_LATIN); + mLanguageToScript.put("pt", SCRIPT_LATIN); mLanguageToScript.put("ru", SCRIPT_CYRILLIC); // TODO: Make a persian proximity, and activate the Farsi subtype. // mLanguageToScript.put("fa", SCRIPT_PERSIAN); |