am cbf54dea: Merge "[IL92] Straighten out showSuggestionStripWithTypedWord"
* commit 'cbf54dea49151e3d8a8dff5074d289ce38dd0698': [IL92] Straighten out showSuggestionStripWithTypedWordmain
commit
d5259d578b
|
@ -1426,7 +1426,6 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
|
|||
|
||||
private void showSuggestionStripWithTypedWord(final SuggestedWords sourceSuggestedWords,
|
||||
final String typedWord) {
|
||||
// TODO: refactor this
|
||||
final SuggestedWords suggestedWords =
|
||||
sourceSuggestedWords.isEmpty() ? SuggestedWords.EMPTY : sourceSuggestedWords;
|
||||
final String autoCorrection;
|
||||
|
@ -1437,13 +1436,9 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
|
|||
// because it may differ from mWordComposer.mTypedWord.
|
||||
autoCorrection = typedWord;
|
||||
}
|
||||
if (suggestedWords.isEmpty()) {
|
||||
AccessibilityUtils.getInstance().setAutoCorrection(suggestedWords, typedWord);
|
||||
setSuggestedWords(suggestedWords);
|
||||
setAutoCorrectionIndicator(false);
|
||||
return;
|
||||
if (SuggestedWords.EMPTY != suggestedWords) {
|
||||
mInputLogic.mWordComposer.setAutoCorrection(autoCorrection);
|
||||
}
|
||||
mInputLogic.mWordComposer.setAutoCorrection(autoCorrection);
|
||||
setSuggestedWords(suggestedWords);
|
||||
setAutoCorrectionIndicator(suggestedWords.mWillAutoCorrect);
|
||||
setSuggestionStripShown(isSuggestionsStripVisible());
|
||||
|
|
Loading…
Reference in New Issue