Merge "Small reorganization"
This commit is contained in:
commit
d17ff7225a
1 changed files with 6 additions and 5 deletions
|
@ -1857,6 +1857,11 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
|
|||
|| mSuggestionsView.isShowingAddToDictionaryHint()) {
|
||||
builder.setTypedWordValid(!allowsToBeAutoCorrected).setHasMinimalSuggestion(
|
||||
autoCorrectionAvailable);
|
||||
if (Suggest.shouldBlockAutoCorrectionBySafetyNet(builder, mSuggest,
|
||||
mSettingsValues.mAutoCorrectionThreshold)) {
|
||||
builder.setShouldBlockAutoCorrectionBySafetyNet();
|
||||
}
|
||||
showSuggestions(builder.build(), typedWord);
|
||||
} else {
|
||||
SuggestedWords previousSuggestions = mSuggestionsView.getSuggestions();
|
||||
if (previousSuggestions == mSettingsValues.mSuggestPuncList) {
|
||||
|
@ -1866,13 +1871,9 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
|
|||
previousSuggestions = SuggestedWords.EMPTY;
|
||||
}
|
||||
builder.addTypedWordAndPreviousSuggestions(typedWord, previousSuggestions);
|
||||
}
|
||||
if (Suggest.shouldBlockAutoCorrectionBySafetyNet(builder, mSuggest,
|
||||
mSettingsValues.mAutoCorrectionThreshold)) {
|
||||
builder.setShouldBlockAutoCorrectionBySafetyNet();
|
||||
}
|
||||
showSuggestions(builder.build(), typedWord);
|
||||
}
|
||||
}
|
||||
|
||||
public void showSuggestions(final SuggestedWords suggestedWords, final CharSequence typedWord) {
|
||||
final CharSequence autoCorrection;
|
||||
|
|
Loading…
Reference in a new issue