diff options
author | 2010-08-26 23:54:29 -0700 | |
---|---|---|
committer | 2010-08-26 23:54:29 -0700 | |
commit | 7986d78328e17bdbe7ec05558e93a2c6a25641c6 (patch) | |
tree | 810409d496d54098b2750fa9a50f9f0659fb3850 /java | |
parent | f17a50f5a5a6c185d3a223bea3a7475c8482a110 (diff) | |
parent | cec1495071e0cf78b5941b07768062fbafe2dccd (diff) | |
download | latinime-7986d78328e17bdbe7ec05558e93a2c6a25641c6.tar.gz latinime-7986d78328e17bdbe7ec05558e93a2c6a25641c6.tar.xz latinime-7986d78328e17bdbe7ec05558e93a2c6a25641c6.zip |
Merge "Disable long-press on shift and symbol keys" into gingerbread
Diffstat (limited to 'java')
-rwxr-xr-x | java/res/xml/kbd_phone.xml | 2 | ||||
-rwxr-xr-x | java/res/xml/kbd_phone_black.xml | 2 | ||||
-rwxr-xr-x | java/res/xml/kbd_phone_symbols.xml | 2 | ||||
-rwxr-xr-x | java/res/xml/kbd_phone_symbols_black.xml | 2 | ||||
-rwxr-xr-x | java/res/xml/kbd_qwerty.xml | 10 | ||||
-rwxr-xr-x | java/res/xml/kbd_qwerty_black.xml | 10 | ||||
-rwxr-xr-x | java/res/xml/kbd_symbols.xml | 2 | ||||
-rwxr-xr-x | java/res/xml/kbd_symbols_black.xml | 2 | ||||
-rwxr-xr-x | java/res/xml/kbd_symbols_shift.xml | 2 | ||||
-rwxr-xr-x | java/res/xml/kbd_symbols_shift_black.xml | 2 | ||||
-rw-r--r-- | java/src/com/android/inputmethod/latin/LatinIME.java | 3 | ||||
-rw-r--r-- | java/src/com/android/inputmethod/latin/LatinKeyboardView.java | 14 |
12 files changed, 1 insertions, 52 deletions
diff --git a/java/res/xml/kbd_phone.xml b/java/res/xml/kbd_phone.xml index d2bcdac52..73d022fcb 100755 --- a/java/res/xml/kbd_phone.xml +++ b/java/res/xml/kbd_phone.xml @@ -50,8 +50,6 @@ <Row android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyIcon="@drawable/sym_keyboard_numalt" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:iconPreview="@drawable/sym_keyboard_feedback_numalt"/> <Key android:codes="48" android:keyIcon="@drawable/sym_keyboard_num0"/> diff --git a/java/res/xml/kbd_phone_black.xml b/java/res/xml/kbd_phone_black.xml index b7f9096bd..3738f2b68 100755 --- a/java/res/xml/kbd_phone_black.xml +++ b/java/res/xml/kbd_phone_black.xml @@ -50,8 +50,6 @@ <Row android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyIcon="@drawable/sym_bkeyboard_numalt" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:iconPreview="@drawable/sym_keyboard_feedback_numalt"/> <Key android:codes="48" android:keyIcon="@drawable/sym_bkeyboard_num0"/> diff --git a/java/res/xml/kbd_phone_symbols.xml b/java/res/xml/kbd_phone_symbols.xml index 9604664fa..9196df8da 100755 --- a/java/res/xml/kbd_phone_symbols.xml +++ b/java/res/xml/kbd_phone_symbols.xml @@ -55,8 +55,6 @@ <Row android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_phone_key" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyEdgeFlags="left"/> <Key android:keyLabel="+"/> <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" diff --git a/java/res/xml/kbd_phone_symbols_black.xml b/java/res/xml/kbd_phone_symbols_black.xml index c73e5faa4..b996e8b31 100755 --- a/java/res/xml/kbd_phone_symbols_black.xml +++ b/java/res/xml/kbd_phone_symbols_black.xml @@ -55,8 +55,6 @@ <Row android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_phone_key" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyEdgeFlags="left"/> <Key android:keyLabel="+"/> <Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space" diff --git a/java/res/xml/kbd_qwerty.xml b/java/res/xml/kbd_qwerty.xml index 7cb18b04e..b0450c6cd 100755 --- a/java/res/xml/kbd_qwerty.xml +++ b/java/res/xml/kbd_qwerty.xml @@ -111,8 +111,6 @@ <Row android:keyboardMode="@+id/mode_normal" android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_symbol_key" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyWidth="20%p" android:keyEdgeFlags="left"/> <Key android:codes="@integer/key_f1" android:keyIcon="@drawable/sym_keyboard_mic" android:iconPreview="@drawable/sym_keyboard_feedback_mic" @@ -129,8 +127,6 @@ <Row android:keyboardMode="@+id/mode_url" android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_symbol_key" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyWidth="20%p" android:keyEdgeFlags="left"/> <Key android:keyLabel="/" android:keyWidth="10%p"/> <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" @@ -149,8 +145,6 @@ <Row android:keyboardMode="@+id/mode_email" android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_symbol_key" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyWidth="20%p" android:keyEdgeFlags="left"/> <Key android:keyLabel="\@"/> <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" @@ -168,8 +162,6 @@ <Row android:keyboardMode="@+id/mode_im" android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_symbol_key" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyWidth="20%p" android:keyEdgeFlags="left"/> <Key android:codes="@integer/key_f1" android:keyIcon="@drawable/sym_keyboard_mic" android:iconPreview="@drawable/sym_keyboard_feedback_mic" @@ -186,8 +178,6 @@ <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_symbol_key" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyWidth="20%p" android:keyEdgeFlags="left"/> <Key android:codes="@integer/key_f1" android:keyIcon="@drawable/sym_keyboard_mic" android:iconPreview="@drawable/sym_keyboard_feedback_mic" diff --git a/java/res/xml/kbd_qwerty_black.xml b/java/res/xml/kbd_qwerty_black.xml index d013ae01b..afea2f379 100755 --- a/java/res/xml/kbd_qwerty_black.xml +++ b/java/res/xml/kbd_qwerty_black.xml @@ -111,8 +111,6 @@ <Row android:keyboardMode="@+id/mode_normal" android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_symbol_key" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyWidth="20%p" android:keyEdgeFlags="left"/> <Key android:codes="@integer/key_f1" android:keyIcon="@drawable/sym_bkeyboard_mic" android:iconPreview="@drawable/sym_keyboard_feedback_mic" @@ -129,8 +127,6 @@ <Row android:keyboardMode="@+id/mode_url" android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_symbol_key" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyWidth="20%p" android:keyEdgeFlags="left"/> <Key android:keyLabel="/" android:keyWidth="10%p"/> <Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space" @@ -149,8 +145,6 @@ <Row android:keyboardMode="@+id/mode_email" android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_symbol_key" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyWidth="20%p" android:keyEdgeFlags="left"/> <Key android:keyLabel="\@"/> <Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space" @@ -168,8 +162,6 @@ <Row android:keyboardMode="@+id/mode_im" android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_symbol_key" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyWidth="20%p" android:keyEdgeFlags="left"/> <Key android:codes="@integer/key_f1" android:keyIcon="@drawable/sym_bkeyboard_mic" android:iconPreview="@drawable/sym_keyboard_feedback_mic" @@ -186,8 +178,6 @@ <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_symbol_key" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyWidth="20%p" android:keyEdgeFlags="left"/> <Key android:codes="@integer/key_f1" android:keyIcon="@drawable/sym_bkeyboard_mic" android:iconPreview="@drawable/sym_keyboard_feedback_mic" diff --git a/java/res/xml/kbd_symbols.xml b/java/res/xml/kbd_symbols.xml index ab5792fd1..77eb7d059 100755 --- a/java/res/xml/kbd_symbols.xml +++ b/java/res/xml/kbd_symbols.xml @@ -123,8 +123,6 @@ <Row android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_alpha_key" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyWidth="20%p" android:keyEdgeFlags="left"/> <Key android:codes="@integer/key_f1" android:keyWidth="10%p"/> <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" diff --git a/java/res/xml/kbd_symbols_black.xml b/java/res/xml/kbd_symbols_black.xml index 5652f7fca..5f8dfbeaa 100755 --- a/java/res/xml/kbd_symbols_black.xml +++ b/java/res/xml/kbd_symbols_black.xml @@ -123,8 +123,6 @@ <Row android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_alpha_key" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyWidth="20%p" android:keyEdgeFlags="left"/> <Key android:codes="@integer/key_f1" android:keyWidth="10%p"/> <Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space" diff --git a/java/res/xml/kbd_symbols_shift.xml b/java/res/xml/kbd_symbols_shift.xml index ca431fc8c..467ca529f 100755 --- a/java/res/xml/kbd_symbols_shift.xml +++ b/java/res/xml/kbd_symbols_shift.xml @@ -90,8 +90,6 @@ <Row android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_alpha_key" android:keyWidth="20%p" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyEdgeFlags="left"/> <Key android:keyLabel="„" android:keyWidth="10%p" /> <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" diff --git a/java/res/xml/kbd_symbols_shift_black.xml b/java/res/xml/kbd_symbols_shift_black.xml index a8acb9d00..511ad4981 100755 --- a/java/res/xml/kbd_symbols_shift_black.xml +++ b/java/res/xml/kbd_symbols_shift_black.xml @@ -90,8 +90,6 @@ <Row android:rowEdgeFlags="bottom"> <Key android:codes="-2" android:keyLabel="@string/label_alpha_key" android:keyWidth="20%p" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_" android:keyEdgeFlags="left"/> <Key android:keyLabel="„" android:keyWidth="10%p" /> <Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space" diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java index 2753bb8b9..37ae43d38 100644 --- a/java/src/com/android/inputmethod/latin/LatinIME.java +++ b/java/src/com/android/inputmethod/latin/LatinIME.java @@ -1103,9 +1103,6 @@ public class LatinIME extends InputMethodService case LatinKeyboardView.KEYCODE_PREV_LANGUAGE: toggleLanguage(false, false); break; - case LatinKeyboardView.KEYCODE_SHIFT_LONGPRESS: - handleCapsLock(); - break; case Keyboard.KEYCODE_MODE_CHANGE: changeKeyboardMode(); break; diff --git a/java/src/com/android/inputmethod/latin/LatinKeyboardView.java b/java/src/com/android/inputmethod/latin/LatinKeyboardView.java index e57abd2c5..cca0de18e 100644 --- a/java/src/com/android/inputmethod/latin/LatinKeyboardView.java +++ b/java/src/com/android/inputmethod/latin/LatinKeyboardView.java @@ -34,7 +34,6 @@ import android.widget.PopupWindow; public class LatinKeyboardView extends LatinKeyboardBaseView { static final int KEYCODE_OPTIONS = -100; - static final int KEYCODE_SHIFT_LONGPRESS = -101; static final int KEYCODE_VOICE = -102; static final int KEYCODE_F1 = -103; static final int KEYCODE_NEXT_LANGUAGE = -104; @@ -95,18 +94,7 @@ public class LatinKeyboardView extends LatinKeyboardBaseView { @Override protected boolean onLongPress(Key key) { - if (key.codes[0] == Keyboard.KEYCODE_MODE_CHANGE) { - getOnKeyboardActionListener().onKey(KEYCODE_OPTIONS, null, - LatinKeyboardBaseView.NOT_A_TOUCH_COORDINATE, - LatinKeyboardBaseView.NOT_A_TOUCH_COORDINATE); - return true; - } else if (key.codes[0] == Keyboard.KEYCODE_SHIFT) { - getOnKeyboardActionListener().onKey(KEYCODE_SHIFT_LONGPRESS, null, - LatinKeyboardBaseView.NOT_A_TOUCH_COORDINATE, - LatinKeyboardBaseView.NOT_A_TOUCH_COORDINATE); - invalidateAllKeys(); - return true; - } else if (key.codes[0] == '0' && getKeyboard() == mPhoneKeyboard) { + if (key.codes[0] == '0' && getKeyboard() == mPhoneKeyboard) { // Long pressing on 0 in phone number keypad gives you a '+'. getOnKeyboardActionListener().onKey( '+', null, LatinKeyboardBaseView.NOT_A_TOUCH_COORDINATE, |