Merge "Consolidate updateCorrectionMode() calls"
This commit is contained in:
commit
411a98afb9
1 changed files with 3 additions and 6 deletions
|
@ -402,14 +402,12 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
|
||||||
final Resources res = getResources();
|
final Resources res = getResources();
|
||||||
mResources = res;
|
mResources = res;
|
||||||
|
|
||||||
|
// TODO: remove the following when it's not needed by updateCorrectionMode() any more
|
||||||
|
mInputAttributes = new InputAttributes(null, false /* isFullscreenMode */);
|
||||||
loadSettings();
|
loadSettings();
|
||||||
|
|
||||||
ImfUtils.setAdditionalInputMethodSubtypes(this, mSettingsValues.getAdditionalSubtypes());
|
ImfUtils.setAdditionalInputMethodSubtypes(this, mSettingsValues.getAdditionalSubtypes());
|
||||||
|
|
||||||
// TODO: remove the following when it's not needed by updateCorrectionMode() any more
|
|
||||||
mInputAttributes = new InputAttributes(null, false /* isFullscreenMode */);
|
|
||||||
updateCorrectionMode();
|
|
||||||
|
|
||||||
Utils.GCUtils.getInstance().reset();
|
Utils.GCUtils.getInstance().reset();
|
||||||
boolean tryGC = true;
|
boolean tryGC = true;
|
||||||
for (int i = 0; i < Utils.GCUtils.GC_TRY_LOOP_MAX && tryGC; ++i) {
|
for (int i = 0; i < Utils.GCUtils.GC_TRY_LOOP_MAX && tryGC; ++i) {
|
||||||
|
@ -454,6 +452,7 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
mSettingsValues = job.runInLocale(mResources, mSubtypeSwitcher.getCurrentSubtypeLocale());
|
mSettingsValues = job.runInLocale(mResources, mSubtypeSwitcher.getCurrentSubtypeLocale());
|
||||||
|
updateCorrectionMode();
|
||||||
mFeedbackManager = new AudioAndHapticFeedbackManager(this, mSettingsValues);
|
mFeedbackManager = new AudioAndHapticFeedbackManager(this, mSettingsValues);
|
||||||
resetContactsDictionary(null == mSuggest ? null : mSuggest.getContactsDictionary());
|
resetContactsDictionary(null == mSuggest ? null : mSuggest.getContactsDictionary());
|
||||||
}
|
}
|
||||||
|
@ -700,7 +699,6 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
|
||||||
mSpaceState = SPACE_STATE_NONE;
|
mSpaceState = SPACE_STATE_NONE;
|
||||||
|
|
||||||
loadSettings();
|
loadSettings();
|
||||||
updateCorrectionMode();
|
|
||||||
updateSuggestionVisibility(mResources);
|
updateSuggestionVisibility(mResources);
|
||||||
|
|
||||||
if (mSuggest != null && mSettingsValues.mAutoCorrectEnabled) {
|
if (mSuggest != null && mSettingsValues.mAutoCorrectEnabled) {
|
||||||
|
@ -2200,7 +2198,6 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
|
||||||
mKeyboardSwitcher.loadKeyboard(getCurrentInputEditorInfo(), mSettingsValues);
|
mKeyboardSwitcher.loadKeyboard(getCurrentInputEditorInfo(), mSettingsValues);
|
||||||
}
|
}
|
||||||
initSuggest();
|
initSuggest();
|
||||||
updateCorrectionMode();
|
|
||||||
loadSettings();
|
loadSettings();
|
||||||
// Since we just changed languages, we should re-evaluate suggestions with whatever word
|
// Since we just changed languages, we should re-evaluate suggestions with whatever word
|
||||||
// we are currently composing. If we are not composing anything, we may want to display
|
// we are currently composing. If we are not composing anything, we may want to display
|
||||||
|
|
Loading…
Reference in a new issue