aboutsummaryrefslogtreecommitdiffstats
path: root/java/src
diff options
context:
space:
mode:
authorTadashi G. Takaoka <takaoka@google.com>2014-06-09 08:45:07 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2014-06-09 08:45:07 +0000
commit6dd4465d5f6b63ae944abed595db881d291368e1 (patch)
treed01911c32e862b350f3bee091062762e060e7086 /java/src
parentdf1464d9a2036c345ae2fb696ad978909444408d (diff)
parent48b96a6a52dab6f3a44adf80b40832d629fe5871 (diff)
downloadlatinime-6dd4465d5f6b63ae944abed595db881d291368e1.tar.gz
latinime-6dd4465d5f6b63ae944abed595db881d291368e1.tar.xz
latinime-6dd4465d5f6b63ae944abed595db881d291368e1.zip
am 48b96a6a: Fix TalkBack descriptions of keyboard shift mode transition
* commit '48b96a6a52dab6f3a44adf80b40832d629fe5871': Fix TalkBack descriptions of keyboard shift mode transition
Diffstat (limited to 'java/src')
-rw-r--r--java/src/com/android/inputmethod/accessibility/MainKeyboardAccessibilityDelegate.java14
1 files changed, 14 insertions, 0 deletions
diff --git a/java/src/com/android/inputmethod/accessibility/MainKeyboardAccessibilityDelegate.java b/java/src/com/android/inputmethod/accessibility/MainKeyboardAccessibilityDelegate.java
index 6757a0efc..96f84dde9 100644
--- a/java/src/com/android/inputmethod/accessibility/MainKeyboardAccessibilityDelegate.java
+++ b/java/src/com/android/inputmethod/accessibility/MainKeyboardAccessibilityDelegate.java
@@ -156,14 +156,28 @@ public final class MainKeyboardAccessibilityDelegate
case KeyboardId.ELEMENT_ALPHABET:
if (lastElementId == KeyboardId.ELEMENT_ALPHABET
|| lastElementId == KeyboardId.ELEMENT_ALPHABET_AUTOMATIC_SHIFTED) {
+ // Transition between alphabet mode and automatic shifted mode should be silently
+ // ignored because it can be determined by each key's talk back announce.
return;
}
resId = R.string.spoken_description_mode_alpha;
break;
case KeyboardId.ELEMENT_ALPHABET_MANUAL_SHIFTED:
+ if (lastElementId == KeyboardId.ELEMENT_ALPHABET_AUTOMATIC_SHIFTED) {
+ // Resetting automatic shifted mode by pressing the shift key causes the transition
+ // from automatic shifted to manual shifted that should be silently ignored.
+ return;
+ }
resId = R.string.spoken_description_shiftmode_on;
break;
case KeyboardId.ELEMENT_ALPHABET_SHIFT_LOCK_SHIFTED:
+ if (lastElementId == KeyboardId.ELEMENT_ALPHABET_SHIFT_LOCKED) {
+ // Resetting caps locked mode by pressing the shift key causes the transition
+ // from shift locked to shift lock shifted that should be silently ignored.
+ return;
+ }
+ resId = R.string.spoken_description_shiftmode_locked;
+ break;
case KeyboardId.ELEMENT_ALPHABET_SHIFT_LOCKED:
resId = R.string.spoken_description_shiftmode_locked;
break;