aboutsummaryrefslogtreecommitdiffstats
path: root/java/src/com/android/inputmethod/latin/LatinIME.java
diff options
context:
space:
mode:
authorTadashi G. Takaoka <takaoka@google.com>2011-06-09 14:22:37 +0900
committerTadashi G. Takaoka <takaoka@google.com>2011-06-09 14:22:37 +0900
commitc97810693dfe83bf37c09f73c8d4b40f2ba8dddb (patch)
tree2ed8aa72fcf516343fe11d45218f57c544bc8f80 /java/src/com/android/inputmethod/latin/LatinIME.java
parent3d3e6f5faa8792033b40681eb6b6191e6e735bb7 (diff)
downloadlatinime-c97810693dfe83bf37c09f73c8d4b40f2ba8dddb.tar.gz
latinime-c97810693dfe83bf37c09f73c8d4b40f2ba8dddb.tar.xz
latinime-c97810693dfe83bf37c09f73c8d4b40f2ba8dddb.zip
Introduce CandidateView.Listener
Bug: 4175031 Change-Id: Ie84d1c86ff099350b786c71e7081d9ea9ee0d81f
Diffstat (limited to 'java/src/com/android/inputmethod/latin/LatinIME.java')
-rw-r--r--java/src/com/android/inputmethod/latin/LatinIME.java7
1 files changed, 5 insertions, 2 deletions
diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java
index a4a04ffb1..a71935012 100644
--- a/java/src/com/android/inputmethod/latin/LatinIME.java
+++ b/java/src/com/android/inputmethod/latin/LatinIME.java
@@ -77,7 +77,8 @@ import java.util.Locale;
/**
* Input method implementation for Qwerty'ish keyboard.
*/
-public class LatinIME extends InputMethodServiceCompatWrapper implements KeyboardActionListener {
+public class LatinIME extends InputMethodServiceCompatWrapper implements KeyboardActionListener,
+ CandidateView.Listener {
private static final String TAG = LatinIME.class.getSimpleName();
private static final boolean PERF_DEBUG = false;
private static final boolean TRACE = false;
@@ -491,7 +492,7 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
super.setInputView(view);
mCandidateViewContainer = view.findViewById(R.id.candidates_container);
mCandidateView = (CandidateView) view.findViewById(R.id.candidates);
- mCandidateView.setService(this);
+ mCandidateView.setListener(this);
mCandidateStripHeight = (int)mResources.getDimension(R.dimen.candidate_strip_height);
}
@@ -1000,6 +1001,7 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
}
}
+ @Override
public boolean addWordToDictionary(String word) {
mUserDictionary.addWord(word, 128);
// Suggestion strip should be updated after the operation of adding word to the
@@ -1524,6 +1526,7 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
return false;
}
+ @Override
public void pickSuggestionManually(int index, CharSequence suggestion) {
SuggestedWords suggestions = mCandidateView.getSuggestions();
mVoiceProxy.flushAndLogAllTextModificationCounters(index, suggestion,