aboutsummaryrefslogtreecommitdiffstats
path: root/tests/src/com/android/inputmethod/latin/SuggestHelper.java
diff options
context:
space:
mode:
authorTadashi G. Takaoka <takaoka@google.com>2011-12-16 03:23:50 -0800
committerAndroid Git Automerger <android-git-automerger@android.com>2011-12-16 03:23:50 -0800
commitcfe7fbd3cfc19288dc3833801dcd95168b82cd6d (patch)
treef0d18866fe3af1de0753335ddabb233b0517c4a3 /tests/src/com/android/inputmethod/latin/SuggestHelper.java
parent77590f77a0079da03633a1c0b8a3716030c7a485 (diff)
parentbf7ed75e4fd3d91b20278ffed1850253b3b9a025 (diff)
downloadlatinime-cfe7fbd3cfc19288dc3833801dcd95168b82cd6d.tar.gz
latinime-cfe7fbd3cfc19288dc3833801dcd95168b82cd6d.tar.xz
latinime-cfe7fbd3cfc19288dc3833801dcd95168b82cd6d.zip
am bf7ed75e: Merge "Move KeyboardSwitcher.getKeyboard to KeyboardSet"
* commit 'bf7ed75e4fd3d91b20278ffed1850253b3b9a025': Move KeyboardSwitcher.getKeyboard to KeyboardSet
Diffstat (limited to 'tests/src/com/android/inputmethod/latin/SuggestHelper.java')
-rw-r--r--tests/src/com/android/inputmethod/latin/SuggestHelper.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/src/com/android/inputmethod/latin/SuggestHelper.java b/tests/src/com/android/inputmethod/latin/SuggestHelper.java
index 06b192440..4d123e5d3 100644
--- a/tests/src/com/android/inputmethod/latin/SuggestHelper.java
+++ b/tests/src/com/android/inputmethod/latin/SuggestHelper.java
@@ -32,11 +32,13 @@ public class SuggestHelper {
protected final LatinKeyboard mKeyboard;
private final KeyDetector mKeyDetector;
+ public static final int ALPHABET_KEYBOARD = com.android.inputmethod.latin.R.xml.kbd_qwerty;
+
public SuggestHelper(Context context, int dictionaryId, KeyboardId keyboardId) {
// Use null as the locale for Suggest so as to force it to use the internal dictionary
// (and not try to find a dictionary provider for a specified locale)
mSuggest = new Suggest(context, dictionaryId, null);
- mKeyboard = new LatinKeyboard.Builder(context).load(keyboardId).build();
+ mKeyboard = new LatinKeyboard.Builder(context).load(ALPHABET_KEYBOARD, keyboardId).build();
mKeyDetector = new KeyDetector(0);
init();
}
@@ -45,7 +47,7 @@ public class SuggestHelper {
final long startOffset, final long length, final KeyboardId keyboardId,
final Locale locale) {
mSuggest = new Suggest(context, dictionaryPath, startOffset, length, null, locale);
- mKeyboard = new LatinKeyboard.Builder(context).load(keyboardId).build();
+ mKeyboard = new LatinKeyboard.Builder(context).load(ALPHABET_KEYBOARD, keyboardId).build();
mKeyDetector = new KeyDetector(0);
init();
}