am 3f226af4: Merge "[IL89] Inline a function"

* commit '3f226af439700e9e01eabf7280a5c366e10a3d74':
  [IL89] Inline a function
main
Jean Chalard 2014-01-27 03:22:06 -08:00 committed by Android Git Automerger
commit efef6d87e9
1 changed files with 3 additions and 7 deletions

View File

@ -1329,12 +1329,6 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
} }
} }
// TODO[IL]: Define a clear interface for this
public void clearSuggestionStrip() {
setSuggestedWords(SuggestedWords.EMPTY);
setAutoCorrectionIndicator(false);
}
// TODO[IL]: Define a clear interface for this // TODO[IL]: Define a clear interface for this
public void setSuggestedWords(final SuggestedWords words) { public void setSuggestedWords(final SuggestedWords words) {
mInputLogic.mSuggestedWords = words; mInputLogic.mSuggestedWords = words;
@ -1432,10 +1426,12 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
private void showSuggestionStripWithTypedWord(final SuggestedWords suggestedWords, private void showSuggestionStripWithTypedWord(final SuggestedWords suggestedWords,
final String typedWord) { final String typedWord) {
// TODO: refactor this
if (suggestedWords.isEmpty()) { if (suggestedWords.isEmpty()) {
// No auto-correction is available, clear the cached values. // No auto-correction is available, clear the cached values.
AccessibilityUtils.getInstance().setAutoCorrection(SuggestedWords.EMPTY, typedWord); AccessibilityUtils.getInstance().setAutoCorrection(SuggestedWords.EMPTY, typedWord);
clearSuggestionStrip(); setSuggestedWords(SuggestedWords.EMPTY);
setAutoCorrectionIndicator(false);
return; return;
} }
final String autoCorrection; final String autoCorrection;