diff options
Diffstat (limited to 'java/src/com/android/inputmethod/latin/LatinIME.java')
-rw-r--r-- | java/src/com/android/inputmethod/latin/LatinIME.java | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java index 29ff0ad83..47137e7fb 100644 --- a/java/src/com/android/inputmethod/latin/LatinIME.java +++ b/java/src/com/android/inputmethod/latin/LatinIME.java @@ -541,7 +541,7 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen shouldKeepUserHistoryDictionaries = true; // TODO: Eliminate this restriction shouldKeepPersonalizationDictionaries = - mSubtypeSwitcher.isSystemLocaleSameAsLocaleOfAllEnabledSubtypes(); + mSubtypeSwitcher.isSystemLocaleSameAsLocaleOfAllEnabledSubtypesOfEnabledImes(); } else { shouldKeepUserHistoryDictionaries = false; shouldKeepPersonalizationDictionaries = false; @@ -1720,9 +1720,10 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen // DO NOT USE THIS for any other purpose than testing. This is information private to LatinIME. @UsedForTesting - /* package for test */ void waitForMainDictionary(final long timeout, final TimeUnit unit) + /* package for test */ void waitForLoadingDictionaries(final long timeout, final TimeUnit unit) throws InterruptedException { - mInputLogic.mSuggest.mDictionaryFacilitator.waitForLoadingMainDictionary(timeout, unit); + mInputLogic.mSuggest.mDictionaryFacilitator.waitForLoadingDictionariesForTesting( + timeout, unit); } // DO NOT USE THIS for any other purpose than testing. This can break the keyboard badly. @@ -1736,6 +1737,13 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen resetSuggest(new Suggest(locale, dictionaryFacilitator)); } + // DO NOT USE THIS for any other purpose than testing. + @UsedForTesting + /* package for test */ void clearPersonalizedDictionariesForTest() { + mInputLogic.mSuggest.mDictionaryFacilitator.clearUserHistoryDictionary(); + mInputLogic.mSuggest.mDictionaryFacilitator.clearPersonalizationDictionary(); + } + public void dumpDictionaryForDebug(final String dictName) { if (mInputLogic.mSuggest == null) { initSuggest(); |