Merge remote branch 'goog/master' into merge

main
satok 2010-09-07 15:48:43 +09:00
commit 41aa565480
28 changed files with 219 additions and 132 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

View File

@ -28,4 +28,5 @@
<bool name="config_swipeDisambiguation">true</bool> <bool name="config_swipeDisambiguation">true</bool>
<!-- Whether or not Popup on key press is enabled by default --> <!-- Whether or not Popup on key press is enabled by default -->
<bool name="default_popup_preview">true</bool> <bool name="default_popup_preview">true</bool>
<bool name="default_recorrection_enabled">true</bool>
</resources> </resources>

View File

@ -339,6 +339,10 @@
<string name="prefs_enable_log">Enable user feedback</string> <string name="prefs_enable_log">Enable user feedback</string>
<!-- Description for enabling to send user statistics to Google. --> <!-- Description for enabling to send user statistics to Google. -->
<string name="prefs_description_log">Help improve this input method editor by automatically sending usage statistics and crash reports to Google.</string> <string name="prefs_description_log">Help improve this input method editor by automatically sending usage statistics and crash reports to Google.</string>
<!-- Preferences item for enabling to re-correct suggestions . -->
<string name="prefs_enable_recorrection">Tap to re-correction</string>
<!-- The summary for the preferences item for enabling to re-correct suggestions . -->
<string name="prefs_enable_recorrection_summary">You can re-correct words by tapping words you have typed</string>
<!-- Description for keyboard theme switcher --> <!-- Description for keyboard theme switcher -->
<string name="keyboard_layout">Keyboard Theme</string> <string name="keyboard_layout">Keyboard Theme</string>

View File

@ -157,11 +157,11 @@
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="\@"/> <Key android:keyLabel="\@" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"/> <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"
android:iconPreview="@drawable/sym_keyboard_feedback_return" android:iconPreview="@drawable/sym_keyboard_feedback_return"
android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/> android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/>
@ -188,7 +188,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left" android:isModifier="true"/> android:keyWidth="15%p" android:keyEdgeFlags="left" android:isModifier="true"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
@ -197,10 +197,10 @@
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"

View File

@ -187,7 +187,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left"/> android:keyWidth="15%p" android:keyEdgeFlags="left"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
@ -196,10 +196,10 @@
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true"/> android:keyWidth="30%p" android:isRepeatable="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p"/> android:keyWidth="10%p"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return"

View File

@ -137,11 +137,11 @@
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="\@"/> <Key android:keyLabel="\@" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"/> <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"
android:iconPreview="@drawable/sym_keyboard_feedback_return" android:iconPreview="@drawable/sym_keyboard_feedback_return"
android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/> android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/>
@ -168,7 +168,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left" android:isModifier="true"/> android:keyWidth="15%p" android:keyEdgeFlags="left" android:isModifier="true"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
@ -177,10 +177,10 @@
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"

View File

@ -168,7 +168,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left"/> android:keyWidth="15%p" android:keyEdgeFlags="left"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
@ -177,10 +177,10 @@
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true"/> android:keyWidth="30%p" android:isRepeatable="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p"/> android:keyWidth="10%p"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return"

View File

@ -139,11 +139,11 @@
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="\@"/> <Key android:keyLabel="\@" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"/> <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"
android:iconPreview="@drawable/sym_keyboard_feedback_return" android:iconPreview="@drawable/sym_keyboard_feedback_return"
android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/> android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/>
@ -170,7 +170,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left" android:isModifier="true"/> android:keyWidth="15%p" android:keyEdgeFlags="left" android:isModifier="true"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
@ -179,10 +179,10 @@
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"

View File

@ -170,7 +170,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left"/> android:keyWidth="15%p" android:keyEdgeFlags="left"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
@ -179,10 +179,10 @@
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true"/> android:keyWidth="30%p" android:isRepeatable="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p"/> android:keyWidth="10%p"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return"

View File

@ -111,11 +111,11 @@
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="\@"/> <Key android:keyLabel="\@" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"/> <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"
android:iconPreview="@drawable/sym_keyboard_feedback_return" android:iconPreview="@drawable/sym_keyboard_feedback_return"
android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/> android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/>
@ -142,7 +142,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left" android:isModifier="true"/> android:keyWidth="15%p" android:keyEdgeFlags="left" android:isModifier="true"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
@ -151,10 +151,10 @@
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"

View File

@ -142,7 +142,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left"/> android:keyWidth="15%p" android:keyEdgeFlags="left"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
@ -151,10 +151,10 @@
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true"/> android:keyWidth="30%p" android:isRepeatable="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p"/> android:keyWidth="10%p"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return"

View File

@ -155,11 +155,11 @@
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="\@"/> <Key android:keyLabel="\@" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"/> <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"
android:iconPreview="@drawable/sym_keyboard_feedback_return" android:iconPreview="@drawable/sym_keyboard_feedback_return"
android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/> android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/>
@ -186,7 +186,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left" android:isModifier="true"/> android:keyWidth="15%p" android:keyEdgeFlags="left" android:isModifier="true"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
@ -195,10 +195,10 @@
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"

View File

@ -186,7 +186,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left"/> android:keyWidth="15%p" android:keyEdgeFlags="left"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
@ -195,10 +195,10 @@
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true"/> android:keyWidth="30%p" android:isRepeatable="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p"/> android:keyWidth="10%p"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return"

View File

@ -123,11 +123,11 @@
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="\@"/> <Key android:keyLabel="\@" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"/> <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"
android:iconPreview="@drawable/sym_keyboard_feedback_return" android:iconPreview="@drawable/sym_keyboard_feedback_return"
android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/> android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/>
@ -154,7 +154,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left" android:isModifier="true"/> android:keyWidth="15%p" android:keyEdgeFlags="left" android:isModifier="true"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
@ -163,10 +163,10 @@
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"

View File

@ -154,7 +154,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left"/> android:keyWidth="15%p" android:keyEdgeFlags="left"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
@ -163,10 +163,10 @@
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true"/> android:keyWidth="30%p" android:isRepeatable="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p"/> android:keyWidth="10%p"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return"

View File

@ -119,11 +119,11 @@
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="\@"/> <Key android:keyLabel="\@" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"/> <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"
android:iconPreview="@drawable/sym_keyboard_feedback_return" android:iconPreview="@drawable/sym_keyboard_feedback_return"
android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/> android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/>
@ -150,7 +150,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left" android:isModifier="true"/> android:keyWidth="15%p" android:keyEdgeFlags="left" android:isModifier="true"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
@ -159,10 +159,10 @@
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"

View File

@ -150,7 +150,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left"/> android:keyWidth="15%p" android:keyEdgeFlags="left"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
@ -159,10 +159,10 @@
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true"/> android:keyWidth="30%p" android:isRepeatable="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p"/> android:keyWidth="10%p"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return"

View File

@ -159,11 +159,11 @@
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="\@"/> <Key android:keyLabel="\@" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"/> <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"
android:iconPreview="@drawable/sym_keyboard_feedback_return" android:iconPreview="@drawable/sym_keyboard_feedback_return"
android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/> android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/>
@ -190,7 +190,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left" android:isModifier="true"/> android:keyWidth="15%p" android:keyEdgeFlags="left" android:isModifier="true"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
@ -199,10 +199,10 @@
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"

View File

@ -190,7 +190,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left"/> android:keyWidth="15%p" android:keyEdgeFlags="left"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
@ -199,10 +199,10 @@
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true"/> android:keyWidth="30%p" android:isRepeatable="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p"/> android:keyWidth="10%p"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return"

View File

@ -165,11 +165,11 @@
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="\@"/> <Key android:keyLabel="\@" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"/> <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"
android:iconPreview="@drawable/sym_keyboard_feedback_return" android:iconPreview="@drawable/sym_keyboard_feedback_return"
android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/> android:keyWidth="25%p" android:keyEdgeFlags="right" android:isModifier="true"/>
@ -196,7 +196,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left" android:isModifier="true"/> android:keyWidth="15%p" android:keyEdgeFlags="left" android:isModifier="true"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_keyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
@ -205,10 +205,10 @@
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true" android:isModifier="true"/> android:keyWidth="30%p" android:isRepeatable="true" android:isModifier="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_keyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p" android:isModifier="true"/> android:keyWidth="10%p" android:isModifier="true"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"

View File

@ -193,7 +193,7 @@
<Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom"> <Row android:keyboardMode="@+id/mode_webentry" android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyLabel="@string/label_symbol_key" <Key android:codes="-2" android:keyLabel="@string/label_symbol_key"
android:keyWidth="10%p" android:keyEdgeFlags="left"/> android:keyWidth="15%p" android:keyEdgeFlags="left"/>
<Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings" <Key android:codes="@integer/key_settings" android:keyIcon="@drawable/sym_bkeyboard_settings"
android:iconPreview="@drawable/sym_keyboard_feedback_settings" android:iconPreview="@drawable/sym_keyboard_feedback_settings"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
@ -202,10 +202,10 @@
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space" <Key android:codes="32" android:keyIcon="@drawable/sym_bkeyboard_space"
android:iconPreview="@drawable/sym_keyboard_feedback_space" android:iconPreview="@drawable/sym_keyboard_feedback_space"
android:keyWidth="20%p" android:isRepeatable="true"/> android:keyWidth="30%p" android:isRepeatable="true"/>
<Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab" <Key android:codes="9" android:keyIcon="@drawable/sym_bkeyboard_tab"
android:iconPreview="@drawable/sym_keyboard_feedback_tab" android:iconPreview="@drawable/sym_keyboard_feedback_tab"
android:keyWidth="15%p"/> android:keyWidth="10%p"/>
<Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation" <Key android:keyLabel="." android:popupKeyboard="@xml/popup_punctuation"
android:keyWidth="10%p"/> android:keyWidth="10%p"/>
<Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return" <Key android:codes="10" android:keyIcon="@drawable/sym_bkeyboard_return"

View File

@ -37,6 +37,13 @@
android:defaultValue="@bool/default_popup_preview" android:defaultValue="@bool/default_popup_preview"
/> />
<CheckBoxPreference
android:key="recorrection_enabled"
android:title="@string/prefs_enable_recorrection"
android:persistent="true"
android:defaultValue="@bool/default_recorrection_enabled"
/>
<CheckBoxPreference <CheckBoxPreference
android:key="auto_cap" android:key="auto_cap"
android:title="@string/auto_cap" android:title="@string/auto_cap"

View File

@ -16,10 +16,6 @@
package com.android.inputmethod.latin; package com.android.inputmethod.latin;
import java.util.HashMap;
import java.util.Locale;
import java.util.Map;
import android.content.Context; import android.content.Context;
import android.content.SharedPreferences; import android.content.SharedPreferences;
import android.content.res.Configuration; import android.content.res.Configuration;
@ -27,6 +23,10 @@ import android.content.res.Resources;
import android.preference.PreferenceManager; import android.preference.PreferenceManager;
import android.view.InflateException; import android.view.InflateException;
import java.util.HashMap;
import java.util.Locale;
import java.util.Map;
public class KeyboardSwitcher implements SharedPreferences.OnSharedPreferenceChangeListener { public class KeyboardSwitcher implements SharedPreferences.OnSharedPreferenceChangeListener {
public static final int MODE_NONE = 0; public static final int MODE_NONE = 0;
@ -197,8 +197,7 @@ public class KeyboardSwitcher implements SharedPreferences.OnSharedPreferenceCha
} }
mHasVoice = enableVoice; mHasVoice = enableVoice;
mVoiceOnPrimary = voiceOnPrimary; mVoiceOnPrimary = voiceOnPrimary;
setKeyboardMode(mMode, mImeOptions, mHasVoice, setKeyboardMode(mMode, mImeOptions, mHasVoice, mIsSymbols);
mIsSymbols);
} }
boolean hasVoiceButton(boolean isSymbols) { boolean hasVoiceButton(boolean isSymbols) {
@ -338,19 +337,23 @@ public class KeyboardSwitcher implements SharedPreferences.OnSharedPreferenceCha
void toggleShift() { void toggleShift() {
if (mCurrentId.equals(mSymbolsId)) { if (mCurrentId.equals(mSymbolsId)) {
LatinKeyboard symbolsKeyboard = getKeyboard(mSymbolsId);
LatinKeyboard symbolsShiftedKeyboard = getKeyboard(mSymbolsShiftedId); LatinKeyboard symbolsShiftedKeyboard = getKeyboard(mSymbolsShiftedId);
symbolsKeyboard.setShifted(true);
mCurrentId = mSymbolsShiftedId; mCurrentId = mSymbolsShiftedId;
mInputView.setKeyboard(symbolsShiftedKeyboard); mInputView.setKeyboard(symbolsShiftedKeyboard);
symbolsShiftedKeyboard.setShifted(true); // Symbol shifted keyboard has an ALT key that has a caps lock style indicator. To
// enable the indicator, we need to call enableShiftLock() and setShiftLocked(true).
// Thus we can keep the ALT key's Key.on value true while LatinKey.onRelease() is
// called.
symbolsShiftedKeyboard.enableShiftLock();
symbolsShiftedKeyboard.setShiftLocked(true);
symbolsShiftedKeyboard.setImeOptions(mContext.getResources(), mMode, mImeOptions); symbolsShiftedKeyboard.setImeOptions(mContext.getResources(), mMode, mImeOptions);
} else if (mCurrentId.equals(mSymbolsShiftedId)) { } else if (mCurrentId.equals(mSymbolsShiftedId)) {
LatinKeyboard symbolsKeyboard = getKeyboard(mSymbolsId); LatinKeyboard symbolsKeyboard = getKeyboard(mSymbolsId);
LatinKeyboard symbolsShiftedKeyboard = getKeyboard(mSymbolsShiftedId);
symbolsShiftedKeyboard.setShifted(false);
mCurrentId = mSymbolsId; mCurrentId = mSymbolsId;
mInputView.setKeyboard(symbolsKeyboard); mInputView.setKeyboard(symbolsKeyboard);
// Symbol keyboard has an ALT key that has a caps lock style indicator. To disable the
// indicator, we need to call enableShiftLock() and setShiftLocked(false).
symbolsKeyboard.enableShiftLock();
symbolsKeyboard.setShifted(false); symbolsKeyboard.setShifted(false);
symbolsKeyboard.setImeOptions(mContext.getResources(), mMode, mImeOptions); symbolsKeyboard.setImeOptions(mContext.getResources(), mMode, mImeOptions);
} }
@ -365,6 +368,10 @@ public class KeyboardSwitcher implements SharedPreferences.OnSharedPreferenceCha
} }
} }
public boolean hasDistinctMultitouch() {
return mInputView != null && mInputView.hasDistinctMultitouch();
}
/** /**
* Updates state machine to figure out when to automatically switch back to alpha mode. * Updates state machine to figure out when to automatically switch back to alpha mode.
* Returns true if the keyboard needs to switch back * Returns true if the keyboard needs to switch back

View File

@ -127,6 +127,7 @@ public class LatinIME extends InputMethodService
public static final String PREF_SELECTED_LANGUAGES = "selected_languages"; public static final String PREF_SELECTED_LANGUAGES = "selected_languages";
public static final String PREF_INPUT_LANGUAGE = "input_language"; public static final String PREF_INPUT_LANGUAGE = "input_language";
private static final String PREF_RECORRECTION_ENABLED = "recorrection_enabled";
private static final int MSG_UPDATE_SUGGESTIONS = 0; private static final int MSG_UPDATE_SUGGESTIONS = 0;
private static final int MSG_START_TUTORIAL = 1; private static final int MSG_START_TUTORIAL = 1;
@ -193,6 +194,7 @@ public class LatinIME extends InputMethodService
private boolean mAutoSpace; private boolean mAutoSpace;
private boolean mJustAddedAutoSpace; private boolean mJustAddedAutoSpace;
private boolean mAutoCorrectEnabled; private boolean mAutoCorrectEnabled;
private boolean mReCorrectionEnabled;
private boolean mBigramSuggestionEnabled; private boolean mBigramSuggestionEnabled;
private boolean mAutoCorrectOn; private boolean mAutoCorrectOn;
// TODO move this state variable outside LatinIME // TODO move this state variable outside LatinIME
@ -360,6 +362,8 @@ public class LatinIME extends InputMethodService
if (inputLanguage == null) { if (inputLanguage == null) {
inputLanguage = conf.locale.toString(); inputLanguage = conf.locale.toString();
} }
mReCorrectionEnabled = prefs.getBoolean(PREF_RECORRECTION_ENABLED,
getResources().getBoolean(R.bool.default_recorrection_enabled));
LatinIMEUtil.GCUtils.getInstance().reset(); LatinIMEUtil.GCUtils.getInstance().reset();
boolean tryGC = true; boolean tryGC = true;
@ -768,7 +772,7 @@ public class LatinIME extends InputMethodService
mLastSelectionStart = newSelStart; mLastSelectionStart = newSelStart;
mLastSelectionEnd = newSelEnd; mLastSelectionEnd = newSelEnd;
if (mReCorrectionEnabled) {
// Don't look for corrections if the keyboard is not visible // Don't look for corrections if the keyboard is not visible
if (mKeyboardSwitcher != null && mKeyboardSwitcher.getInputView() != null if (mKeyboardSwitcher != null && mKeyboardSwitcher.getInputView() != null
&& mKeyboardSwitcher.getInputView().isShown()) { && mKeyboardSwitcher.getInputView().isShown()) {
@ -787,6 +791,7 @@ public class LatinIME extends InputMethodService
} }
} }
} }
}
@Override @Override
public void hideWindow() { public void hideWindow() {
@ -1134,7 +1139,9 @@ public class LatinIME extends InputMethodService
LatinImeLogger.logOnDelete(); LatinImeLogger.logOnDelete();
break; break;
case Keyboard.KEYCODE_SHIFT: case Keyboard.KEYCODE_SHIFT:
// Shift key is handled in onPress(). // Shift key is handled in onPress() when device has distinct multi-touch panel.
if (!mKeyboardSwitcher.hasDistinctMultitouch())
handleShift();
break; break;
case Keyboard.KEYCODE_CANCEL: case Keyboard.KEYCODE_CANCEL:
if (!isShowingOptionDialog()) { if (!isShowingOptionDialog()) {
@ -1934,7 +1941,7 @@ public class LatinIME extends InputMethodService
List<CharSequence> suggestions = mWordToSuggestions.get(selectedWord); List<CharSequence> suggestions = mWordToSuggestions.get(selectedWord);
// If the first letter of touching is capitalized, make all the suggestions // If the first letter of touching is capitalized, make all the suggestions
// start with a capital letter. // start with a capital letter.
if (Character.isUpperCase((char) touching.word.charAt(0))) { if (Character.isUpperCase(touching.word.charAt(0))) {
for (int i = 0; i < suggestions.size(); i++) { for (int i = 0; i < suggestions.size(); i++) {
String origSugg = (String) suggestions.get(i); String origSugg = (String) suggestions.get(i);
String capsSugg = origSugg.toUpperCase().charAt(0) String capsSugg = origSugg.toUpperCase().charAt(0)
@ -2178,6 +2185,9 @@ public class LatinIME extends InputMethodService
if (PREF_SELECTED_LANGUAGES.equals(key)) { if (PREF_SELECTED_LANGUAGES.equals(key)) {
mLanguageSwitcher.loadLocales(sharedPreferences); mLanguageSwitcher.loadLocales(sharedPreferences);
mRefreshKeyboardRequired = true; mRefreshKeyboardRequired = true;
} else if (PREF_RECORRECTION_ENABLED.equals(key)) {
mReCorrectionEnabled = sharedPreferences.getBoolean(PREF_RECORRECTION_ENABLED,
getResources().getBoolean(R.bool.default_recorrection_enabled));
} }
} }
@ -2195,7 +2205,7 @@ public class LatinIME extends InputMethodService
public void onPress(int primaryCode) { public void onPress(int primaryCode) {
vibrate(); vibrate();
playKeyClick(primaryCode); playKeyClick(primaryCode);
if (primaryCode == Keyboard.KEYCODE_SHIFT) { if (mKeyboardSwitcher.hasDistinctMultitouch() && primaryCode == Keyboard.KEYCODE_SHIFT) {
mShiftKeyState.onPress(); mShiftKeyState.onPress();
handleShift(); handleShift();
} else if (primaryCode == Keyboard.KEYCODE_MODE_CHANGE) { } else if (primaryCode == Keyboard.KEYCODE_MODE_CHANGE) {
@ -2209,7 +2219,7 @@ public class LatinIME extends InputMethodService
// Reset any drag flags in the keyboard // Reset any drag flags in the keyboard
((LatinKeyboard) mKeyboardSwitcher.getInputView().getKeyboard()).keyReleased(); ((LatinKeyboard) mKeyboardSwitcher.getInputView().getKeyboard()).keyReleased();
//vibrate(); //vibrate();
if (primaryCode == Keyboard.KEYCODE_SHIFT) { if (mKeyboardSwitcher.hasDistinctMultitouch() && primaryCode == Keyboard.KEYCODE_SHIFT) {
if (mShiftKeyState.isMomentary()) if (mShiftKeyState.isMomentary())
resetShift(); resetShift();
mShiftKeyState.onRelease(); mShiftKeyState.onRelease();

View File

@ -16,9 +16,6 @@
package com.android.inputmethod.latin; package com.android.inputmethod.latin;
import java.util.List;
import java.util.Locale;
import android.content.Context; import android.content.Context;
import android.content.res.Resources; import android.content.res.Resources;
import android.content.res.TypedArray; import android.content.res.TypedArray;
@ -27,10 +24,10 @@ import android.graphics.Bitmap;
import android.graphics.Canvas; import android.graphics.Canvas;
import android.graphics.ColorFilter; import android.graphics.ColorFilter;
import android.graphics.Paint; import android.graphics.Paint;
import android.graphics.Paint.Align;
import android.graphics.PixelFormat; import android.graphics.PixelFormat;
import android.graphics.PorterDuff; import android.graphics.PorterDuff;
import android.graphics.Rect; import android.graphics.Rect;
import android.graphics.Paint.Align;
import android.graphics.drawable.BitmapDrawable; import android.graphics.drawable.BitmapDrawable;
import android.graphics.drawable.Drawable; import android.graphics.drawable.Drawable;
import android.inputmethodservice.Keyboard; import android.inputmethodservice.Keyboard;
@ -39,6 +36,9 @@ import android.util.Log;
import android.view.ViewConfiguration; import android.view.ViewConfiguration;
import android.view.inputmethod.EditorInfo; import android.view.inputmethod.EditorInfo;
import java.util.List;
import java.util.Locale;
public class LatinKeyboard extends Keyboard { public class LatinKeyboard extends Keyboard {
private static final boolean DEBUG_PREFERRED_LETTER = false; private static final boolean DEBUG_PREFERRED_LETTER = false;
@ -128,7 +128,7 @@ public class LatinKeyboard extends Keyboard {
R.dimen.spacebar_vertical_correction); R.dimen.spacebar_vertical_correction);
mIsAlphaKeyboard = xmlLayoutResId == R.xml.kbd_qwerty mIsAlphaKeyboard = xmlLayoutResId == R.xml.kbd_qwerty
|| xmlLayoutResId == R.xml.kbd_qwerty_black; || xmlLayoutResId == R.xml.kbd_qwerty_black;
mSpaceKeyIndex = indexOf((int) ' '); mSpaceKeyIndex = indexOf(' ');
} }
public LatinKeyboard(Context context, int layoutTemplateResId, public LatinKeyboard(Context context, int layoutTemplateResId,

View File

@ -17,6 +17,7 @@
package com.android.inputmethod.latin; package com.android.inputmethod.latin;
import android.content.Context; import android.content.Context;
import android.content.pm.PackageManager;
import android.content.res.Resources; import android.content.res.Resources;
import android.content.res.TypedArray; import android.content.res.TypedArray;
import android.graphics.Bitmap; import android.graphics.Bitmap;
@ -204,6 +205,8 @@ public class LatinKeyboardBaseView extends View implements PointerTracker.UIProx
private final ArrayList<PointerTracker> mPointerTrackers = new ArrayList<PointerTracker>(); private final ArrayList<PointerTracker> mPointerTrackers = new ArrayList<PointerTracker>();
private final PointerQueue mPointerQueue = new PointerQueue(); private final PointerQueue mPointerQueue = new PointerQueue();
private final float mDebounceHysteresis; private final float mDebounceHysteresis;
private final boolean mHasDistinctMultitouch;
private int mOldPointerCount = 1;
protected KeyDetector mKeyDetector = new ProximityKeyDetector(); protected KeyDetector mKeyDetector = new ProximityKeyDetector();
@ -508,6 +511,9 @@ public class LatinKeyboardBaseView extends View implements PointerTracker.UIProx
final boolean ignoreMultitouch = true; final boolean ignoreMultitouch = true;
mGestureDetector = new GestureDetector(getContext(), listener, null, ignoreMultitouch); mGestureDetector = new GestureDetector(getContext(), listener, null, ignoreMultitouch);
mGestureDetector.setIsLongpressEnabled(false); mGestureDetector.setIsLongpressEnabled(false);
mHasDistinctMultitouch = context.getPackageManager()
.hasSystemFeature(PackageManager.FEATURE_TOUCHSCREEN_MULTITOUCH_DISTINCT);
} }
public void setOnKeyboardActionListener(OnKeyboardActionListener listener) { public void setOnKeyboardActionListener(OnKeyboardActionListener listener) {
@ -563,6 +569,14 @@ public class LatinKeyboardBaseView extends View implements PointerTracker.UIProx
return mKeyboard; return mKeyboard;
} }
/**
* Return whether the device has distinct multi-touch panel.
* @return true if the device has distinct multi-touch panel.
*/
public boolean hasDistinctMultitouch() {
return mHasDistinctMultitouch;
}
/** /**
* Sets the state of the shift key of the keyboard, if any. * Sets the state of the shift key of the keyboard, if any.
* @param shifted whether or not to enable the state of the shift key * @param shifted whether or not to enable the state of the shift key
@ -1059,7 +1073,8 @@ public class LatinKeyboardBaseView extends View implements PointerTracker.UIProx
mMiniKeyboardOriginY = y + container.getPaddingTop(); mMiniKeyboardOriginY = y + container.getPaddingTop();
mMiniKeyboard.setPopupOffset((x < 0) ? 0 : x, y); mMiniKeyboard.setPopupOffset((x < 0) ? 0 : x, y);
mMiniKeyboard.setShifted(isShifted()); mMiniKeyboard.setShifted(isShifted());
mMiniKeyboard.setPreviewEnabled(isPreviewEnabled()); // Mini keyboard needs no pop-up key preview displayed.
mMiniKeyboard.setPreviewEnabled(false);
mMiniKeyboardPopup.setContentView(container); mMiniKeyboardPopup.setContentView(container);
mMiniKeyboardPopup.setWidth(container.getMeasuredWidth()); mMiniKeyboardPopup.setWidth(container.getMeasuredWidth());
mMiniKeyboardPopup.setHeight(container.getMeasuredHeight()); mMiniKeyboardPopup.setHeight(container.getMeasuredHeight());
@ -1090,7 +1105,7 @@ public class LatinKeyboardBaseView extends View implements PointerTracker.UIProx
// Create pointer trackers until we can get 'id+1'-th tracker, if needed. // Create pointer trackers until we can get 'id+1'-th tracker, if needed.
for (int i = pointers.size(); i <= id; i++) { for (int i = pointers.size(); i <= id; i++) {
final PointerTracker tracker = final PointerTracker tracker =
new PointerTracker(i, mHandler, mKeyDetector, this); new PointerTracker(i, mHandler, mKeyDetector, this, mHasDistinctMultitouch);
if (keys != null) if (keys != null)
tracker.setKeyboard(keys, mDebounceHysteresis); tracker.setKeyboard(keys, mDebounceHysteresis);
if (listener != null) if (listener != null)
@ -1107,6 +1122,13 @@ public class LatinKeyboardBaseView extends View implements PointerTracker.UIProx
final int action = me.getActionMasked(); final int action = me.getActionMasked();
final long eventTime = me.getEventTime(); final long eventTime = me.getEventTime();
// TODO: cleanup this code into a multi-touch to single-touch event converter class?
// If the device does not have distinct multi-touch support panel, ignore all multi-touch
// events except a transition from/to single-touch.
if (!mHasDistinctMultitouch && pointerCount > 1 && mOldPointerCount > 1) {
return true;
}
// Track the last few movements to look for spurious swipes. // Track the last few movements to look for spurious swipes.
mSwipeTracker.addMovement(me); mSwipeTracker.addMovement(me);
@ -1138,6 +1160,34 @@ public class LatinKeyboardBaseView extends View implements PointerTracker.UIProx
// Up event will pass through. // Up event will pass through.
} }
// TODO: cleanup this code into a multi-touch to single-touch event converter class?
// Translate mutli-touch event to single-touch events on the device that has no distinct
// multi-touch panel.
if (!mHasDistinctMultitouch) {
// Use only main (id=0) pointer tracker.
PointerTracker tracker = getPointerTracker(0);
int index = me.getActionIndex();
int x = (int)me.getX(index);
int y = (int)me.getY(index);
int oldPointerCount = mOldPointerCount;
if (pointerCount == 1 && oldPointerCount == 2) {
// Multi-touch to single touch transition.
// Send a down event for the latest pointer.
tracker.onDownEvent(x, y, eventTime);
} else if (pointerCount == 2 && oldPointerCount == 1) {
// Single-touch to multi-touch transition.
// Send an up event for the last pointer.
tracker.onUpEvent(tracker.getLastX(), tracker.getLastY(), eventTime);
} else if (pointerCount == 1 && oldPointerCount == 1) {
tracker.onTouchEvent(action, x, y, eventTime);
} else {
Log.w(TAG, "Unknown touch panel behavior: pointer count is " + pointerCount
+ " (old " + oldPointerCount + ")");
}
mOldPointerCount = pointerCount;
return true;
}
if (action == MotionEvent.ACTION_MOVE) { if (action == MotionEvent.ACTION_MOVE) {
for (int index = 0; index < pointerCount; index++) { for (int index = 0; index < pointerCount; index++) {
int x = (int)me.getX(index); int x = (int)me.getX(index);

View File

@ -78,17 +78,6 @@ public class LatinKeyboardView extends LatinKeyboardBaseView {
setKeyboardLocal(k); setKeyboardLocal(k);
} }
private static boolean hasOneDigitAlternate(Key key) {
final CharSequence alternates = key.popupCharacters;
if (alternates == null)
return false;
final String altChars = alternates.toString();
if (altChars.codePointCount(0, altChars.length()) != 1)
return false;
final int altCode = altChars.codePointAt(0);
return altCode >= '0' && altCode <= '9';
}
@Override @Override
protected boolean onLongPress(Key key) { protected boolean onLongPress(Key key) {
int primaryCode = key.codes[0]; int primaryCode = key.codes[0];
@ -104,13 +93,6 @@ public class LatinKeyboardView extends LatinKeyboardBaseView {
LatinKeyboardBaseView.NOT_A_TOUCH_COORDINATE, LatinKeyboardBaseView.NOT_A_TOUCH_COORDINATE,
LatinKeyboardBaseView.NOT_A_TOUCH_COORDINATE); LatinKeyboardBaseView.NOT_A_TOUCH_COORDINATE);
return true; return true;
} else if (hasOneDigitAlternate(key)) {
mKeyCodes[0] = primaryCode = key.popupCharacters.charAt(0);
// when there is only one alternate character, send it as key action.
getOnKeyboardActionListener().onKey(primaryCode, mKeyCodes,
LatinKeyboardBaseView.NOT_A_TOUCH_COORDINATE,
LatinKeyboardBaseView.NOT_A_TOUCH_COORDINATE);
return true;
} else { } else {
return super.onLongPress(key); return super.onLongPress(key);
} }
@ -131,7 +113,7 @@ public class LatinKeyboardView extends LatinKeyboardBaseView {
public boolean setShiftLocked(boolean shiftLocked) { public boolean setShiftLocked(boolean shiftLocked) {
Keyboard keyboard = getKeyboard(); Keyboard keyboard = getKeyboard();
if (keyboard != null && keyboard instanceof LatinKeyboard) { if (keyboard instanceof LatinKeyboard) {
((LatinKeyboard)keyboard).setShiftLocked(shiftLocked); ((LatinKeyboard)keyboard).setShiftLocked(shiftLocked);
invalidateAllKeys(); invalidateAllKeys();
return true; return true;

View File

@ -22,12 +22,13 @@ import com.android.inputmethod.latin.LatinKeyboardBaseView.UIHandler;
import android.inputmethodservice.Keyboard; import android.inputmethodservice.Keyboard;
import android.inputmethodservice.Keyboard.Key; import android.inputmethodservice.Keyboard.Key;
import android.util.Log; import android.util.Log;
import android.view.MotionEvent;
import android.view.ViewConfiguration; import android.view.ViewConfiguration;
public class PointerTracker { public class PointerTracker {
private static final String TAG = "PointerTracker"; private static final String TAG = "PointerTracker";
private static final boolean DEBUG = false; private static final boolean DEBUG = false;
private static final boolean DEBUG_MOVE = DEBUG && true; private static final boolean DEBUG_MOVE = false;
public interface UIProxy { public interface UIProxy {
public void invalidateKey(Key key); public void invalidateKey(Key key);
@ -51,6 +52,7 @@ public class PointerTracker {
private final UIHandler mHandler; private final UIHandler mHandler;
private final KeyDetector mKeyDetector; private final KeyDetector mKeyDetector;
private OnKeyboardActionListener mListener; private OnKeyboardActionListener mListener;
private final boolean mHasDistinctMultitouch;
private Key[] mKeys; private Key[] mKeys;
private int mKeyDebounceThresholdSquared = -1; private int mKeyDebounceThresholdSquared = -1;
@ -85,13 +87,15 @@ public class PointerTracker {
// pressed key // pressed key
private int mPreviousKey = NOT_A_KEY; private int mPreviousKey = NOT_A_KEY;
public PointerTracker(int id, UIHandler handler, KeyDetector keyDetector, UIProxy proxy) { public PointerTracker(int id, UIHandler handler, KeyDetector keyDetector, UIProxy proxy,
boolean hasDistinctMultitouch) {
if (proxy == null || handler == null || keyDetector == null) if (proxy == null || handler == null || keyDetector == null)
throw new NullPointerException(); throw new NullPointerException();
mPointerId = id; mPointerId = id;
mProxy = proxy; mProxy = proxy;
mHandler = handler; mHandler = handler;
mKeyDetector = keyDetector; mKeyDetector = keyDetector;
mHasDistinctMultitouch = hasDistinctMultitouch;
resetMultiTap(); resetMultiTap();
} }
@ -146,6 +150,25 @@ public class PointerTracker {
mKeyAlreadyProcessed = true; mKeyAlreadyProcessed = true;
} }
public void onTouchEvent(int action, int x, int y, long eventTime) {
switch (action) {
case MotionEvent.ACTION_MOVE:
onMoveEvent(x, y, eventTime);
break;
case MotionEvent.ACTION_DOWN:
case MotionEvent.ACTION_POINTER_DOWN:
onDownEvent(x, y, eventTime);
break;
case MotionEvent.ACTION_UP:
case MotionEvent.ACTION_POINTER_UP:
onUpEvent(x, y, eventTime);
break;
case MotionEvent.ACTION_CANCEL:
onCancelEvent(x, y, eventTime);
break;
}
}
public void onDownEvent(int x, int y, long eventTime) { public void onDownEvent(int x, int y, long eventTime) {
int keyIndex = mKeyDetector.getKeyIndexAndNearbyCodes(x, y, null); int keyIndex = mKeyDetector.getKeyIndexAndNearbyCodes(x, y, null);
mCurrentKey = keyIndex; mCurrentKey = keyIndex;
@ -242,7 +265,7 @@ public class PointerTracker {
showKeyPreviewAndUpdateKey(NOT_A_KEY); showKeyPreviewAndUpdateKey(NOT_A_KEY);
// If we're not on a repeating key (which sends on a DOWN event) // If we're not on a repeating key (which sends on a DOWN event)
if (!wasInKeyRepeat) { if (!wasInKeyRepeat) {
detectAndSendKey(mCurrentKey, (int)x, (int)y, eventTime); detectAndSendKey(mCurrentKey, x, y, eventTime);
} }
if (isValidKeyIndex(keyIndex)) if (isValidKeyIndex(keyIndex))
mProxy.invalidateKey(mKeys[keyIndex]); mProxy.invalidateKey(mKeys[keyIndex]);
@ -355,7 +378,10 @@ public class PointerTracker {
private void showKeyPreviewAndUpdateKey(int keyIndex) { private void showKeyPreviewAndUpdateKey(int keyIndex) {
updateKey(keyIndex); updateKey(keyIndex);
if (!isModifier()) // The modifier key, such as shift key, should not be shown as preview when multi-touch is
// supported. On thge other hand, if multi-touch is not supported, the modifier key should
// be shown as preview.
if (!isModifier() || !mHasDistinctMultitouch)
mProxy.showPreview(keyIndex, this); mProxy.showPreview(keyIndex, this);
} }