aboutsummaryrefslogtreecommitdiffstats
path: root/java/src
diff options
context:
space:
mode:
authorJean Chalard <jchalard@google.com>2013-12-24 22:46:03 +0900
committerJean Chalard <jchalard@google.com>2013-12-26 21:58:41 +0900
commit70433efc41970b4dc475b7e446388430aaf801b9 (patch)
tree1b3fff92b263f6069a8e369ca833cd180f244b47 /java/src
parentbe147f1fdcfb5d192f64eb97e508b43da1fd9509 (diff)
downloadlatinime-70433efc41970b4dc475b7e446388430aaf801b9.tar.gz
latinime-70433efc41970b4dc475b7e446388430aaf801b9.tar.xz
latinime-70433efc41970b4dc475b7e446388430aaf801b9.zip
[IL41] Remove a useless call and trampoline.
No point in calling maybeRetrieveOlderSuggestions now that the same work is done right here. The callback is also useless now. Bug: 8636060 Change-Id: Ic14849cb6f6e6293a42cfe068f5c6b18b7677bc0
Diffstat (limited to 'java/src')
-rw-r--r--java/src/com/android/inputmethod/latin/LatinIME.java28
1 files changed, 14 insertions, 14 deletions
diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java
index 77def63f1..9e312498c 100644
--- a/java/src/com/android/inputmethod/latin/LatinIME.java
+++ b/java/src/com/android/inputmethod/latin/LatinIME.java
@@ -1377,20 +1377,20 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
private void getSuggestedWordsGestureLocked(final InputPointers batchPointers,
final int sequenceNumber, final OnGetSuggestedWordsCallback callback) {
mLatinIme.mInputLogic.mWordComposer.setBatchInputPointers(batchPointers);
- mLatinIme.getSuggestedWordsOrOlderSuggestionsAsync(Suggest.SESSION_GESTURE,
- sequenceNumber, new OnGetSuggestedWordsCallback() {
- @Override
- public void onGetSuggestedWords(SuggestedWords suggestedWords) {
- if (suggestedWords.isEmpty()) {
- // Previous suggestions are found in InputLogic#mSuggestedWords. Since
- // these are the most recent suggestions and we just recomputed new
- // ones to update them, it means the previous ones are there.
- callback.onGetSuggestedWords(mLatinIme.mInputLogic.mSuggestedWords);
- } else {
- callback.onGetSuggestedWords(suggestedWords);
- }
- }
- });
+ getSuggestedWords(Suggest.SESSION_GESTURE, sequenceNumber,
+ new OnGetSuggestedWordsCallback() {
+ @Override
+ public void onGetSuggestedWords(SuggestedWords suggestedWords) {
+ if (suggestedWords.isEmpty()) {
+ // Previous suggestions are found in InputLogic#mSuggestedWords.
+ // Since these are the most recent ones and we just recomputed new
+ // ones to update them, it means the previous ones are there.
+ callback.onGetSuggestedWords(mLatinIme.mInputLogic.mSuggestedWords);
+ } else {
+ callback.onGetSuggestedWords(suggestedWords);
+ }
+ }
+ });
}
public void getSuggestedWords(final int sessionId, final int sequenceNumber,