aboutsummaryrefslogtreecommitdiffstats
path: root/java/src/com/android/inputmethod/latin/LatinIME.java
diff options
context:
space:
mode:
authorTadashi G. Takaoka <takaoka@google.com>2012-01-17 00:07:38 -0800
committerAndroid (Google) Code Review <android-gerrit@google.com>2012-01-17 00:07:38 -0800
commitc9fade6b87b77251f90ef7d7c03bf70c3b97d889 (patch)
treeecfc99cc2e487d4fc9379dff54084f080886507b /java/src/com/android/inputmethod/latin/LatinIME.java
parentd104a7aac8b0791341c71deb013d4e6adfc57e8a (diff)
parent87e025da11703af65e7bb85670adac5b54e2a367 (diff)
downloadlatinime-c9fade6b87b77251f90ef7d7c03bf70c3b97d889.tar.gz
latinime-c9fade6b87b77251f90ef7d7c03bf70c3b97d889.tar.xz
latinime-c9fade6b87b77251f90ef7d7c03bf70c3b97d889.zip
Merge "Remove toggleShift and toggleAlphabetAndSymbols from KeyboardSwitcher"
Diffstat (limited to 'java/src/com/android/inputmethod/latin/LatinIME.java')
-rw-r--r--java/src/com/android/inputmethod/latin/LatinIME.java21
1 files changed, 5 insertions, 16 deletions
diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java
index f8fef8e92..b0d0da43b 100644
--- a/java/src/com/android/inputmethod/latin/LatinIME.java
+++ b/java/src/com/android/inputmethod/latin/LatinIME.java
@@ -1261,16 +1261,8 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
LatinImeLogger.logOnDelete();
break;
case Keyboard.CODE_SHIFT:
- // Shift key is handled in onPress() when device has distinct multi-touch panel.
- if (!distinctMultiTouch) {
- switcher.toggleShift();
- }
- break;
case Keyboard.CODE_SWITCH_ALPHA_SYMBOL:
- // Symbol key is handled in onPress() when device has distinct multi-touch panel.
- if (!distinctMultiTouch) {
- switcher.toggleAlphabetAndSymbols();
- }
+ // Shift and symbol key is handled in onPress() and onRelease().
break;
case Keyboard.CODE_SETTINGS:
onSettingsKeyPressed();
@@ -2271,10 +2263,9 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
if (switcher.isVibrateAndSoundFeedbackRequired()) {
hapticAndAudioFeedback(primaryCode);
}
- final boolean distinctMultiTouch = switcher.hasDistinctMultitouch();
- if (distinctMultiTouch && primaryCode == Keyboard.CODE_SHIFT) {
+ if (primaryCode == Keyboard.CODE_SHIFT) {
switcher.onPressShift(withSliding);
- } else if (distinctMultiTouch && primaryCode == Keyboard.CODE_SWITCH_ALPHA_SYMBOL) {
+ } else if (primaryCode == Keyboard.CODE_SWITCH_ALPHA_SYMBOL) {
switcher.onPressSymbol();
} else {
switcher.onOtherKeyPressed();
@@ -2284,11 +2275,9 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
@Override
public void onRelease(int primaryCode, boolean withSliding) {
KeyboardSwitcher switcher = mKeyboardSwitcher;
- // Reset any drag flags in the keyboard
- final boolean distinctMultiTouch = switcher.hasDistinctMultitouch();
- if (distinctMultiTouch && primaryCode == Keyboard.CODE_SHIFT) {
+ if (primaryCode == Keyboard.CODE_SHIFT) {
switcher.onReleaseShift(withSliding);
- } else if (distinctMultiTouch && primaryCode == Keyboard.CODE_SWITCH_ALPHA_SYMBOL) {
+ } else if (primaryCode == Keyboard.CODE_SWITCH_ALPHA_SYMBOL) {
switcher.onReleaseSymbol();
}
}