diff options
author | 2012-01-30 20:07:26 -0800 | |
---|---|---|
committer | 2012-01-30 20:07:26 -0800 | |
commit | 30964843db0c3c7892ca443a0513c9c36e8654d1 (patch) | |
tree | d84fde353e679defeb4014f2c8aa21cdd573c838 /java/src/com/android/inputmethod/accessibility/KeyCodeDescriptionMapper.java | |
parent | 16f74396828d84885e922ac0a7467e51616ae71d (diff) | |
parent | ca2f051cc173acc3bce384ebfe08068564bc8e07 (diff) | |
download | latinime-30964843db0c3c7892ca443a0513c9c36e8654d1.tar.gz latinime-30964843db0c3c7892ca443a0513c9c36e8654d1.tar.xz latinime-30964843db0c3c7892ca443a0513c9c36e8654d1.zip |
Merge "Auto generate various shift states alphabet keyboard automatically"
Diffstat (limited to 'java/src/com/android/inputmethod/accessibility/KeyCodeDescriptionMapper.java')
-rw-r--r-- | java/src/com/android/inputmethod/accessibility/KeyCodeDescriptionMapper.java | 21 |
1 files changed, 1 insertions, 20 deletions
diff --git a/java/src/com/android/inputmethod/accessibility/KeyCodeDescriptionMapper.java b/java/src/com/android/inputmethod/accessibility/KeyCodeDescriptionMapper.java index efaf58fc2..3b4149d7f 100644 --- a/java/src/com/android/inputmethod/accessibility/KeyCodeDescriptionMapper.java +++ b/java/src/com/android/inputmethod/accessibility/KeyCodeDescriptionMapper.java @@ -176,25 +176,6 @@ public class KeyCodeDescriptionMapper { } /** - * Returns the keycode for the specified key given the current keyboard - * state. - * - * @param keyboard The keyboard on which the key resides. - * @param key The key from which to obtain a key code. - * @return the key code for the specified key - */ - private int getCorrectKeyCode(Keyboard keyboard, Key key) { - // If keyboard is in manual temporary upper case state and key has - // manual temporary uppercase letter as key hint letter, alternate - // character code should be sent. - if (keyboard.isManualTemporaryUpperCase() && key.hasUppercaseLetter() - && !TextUtils.isEmpty(key.mHintLabel)) { - return key.mHintLabel.charAt(0); - } - return key.mCode; - } - - /** * Returns a localized character sequence describing what will happen when * the specified key is pressed based on its key code. * <p> @@ -217,7 +198,7 @@ public class KeyCodeDescriptionMapper { */ private CharSequence getDescriptionForKeyCode(Context context, Keyboard keyboard, Key key, boolean shouldObscure) { - final int code = getCorrectKeyCode(keyboard, key); + final int code = key.mCode; if (keyboard.isShiftLocked() && mShiftLockedKeyCodeMap.containsKey(code)) { return context.getString(mShiftLockedKeyCodeMap.get(code)); |