diff options
Diffstat (limited to 'java/res/layout')
25 files changed, 169 insertions, 512 deletions
diff --git a/java/res/layout/dictionary_line.xml b/java/res/layout/dictionary_line.xml index 7268cd468..bb1843d6c 100644 --- a/java/res/layout/dictionary_line.xml +++ b/java/res/layout/dictionary_line.xml @@ -42,7 +42,7 @@ android:orientation="vertical"> <TextView - android:id="@+android:id/title" + android:id="@android:id/title" android:layout_marginLeft="5dip" android:layout_marginStart="5dip" android:layout_width="wrap_content" @@ -59,7 +59,7 @@ android:layout_marginLeft="5dip"> <TextView - android:id="@+android:id/summary" + android:id="@android:id/summary" android:layout_width="match_parent" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceSmall" @@ -77,14 +77,14 @@ </LinearLayout> <com.android.inputmethod.dictionarypack.ButtonSwitcher - android:id="@+android:id/wordlist_button_switcher" + android:id="@+id/wordlist_button_switcher" android:layout_weight="0" android:layout_marginStart="13dip" android:layout_marginLeft="13dip" android:layout_width="wrap_content" android:layout_height="wrap_content"> <Button - android:id="@+android:id/dict_install_button" + android:id="@+id/dict_install_button" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="right|center_vertical" @@ -92,7 +92,7 @@ android:textAppearance="?android:attr/textAppearanceMedium" android:text="@string/install_dict" /> <Button - android:id="@+android:id/dict_cancel_button" + android:id="@+id/dict_cancel_button" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="right|center_vertical" @@ -100,7 +100,7 @@ android:textAppearance="?android:attr/textAppearanceMedium" android:text="@string/cancel_download_dict" /> <Button - android:id="@+android:id/dict_delete_button" + android:id="@+id/dict_delete_button" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="right|center_vertical" diff --git a/java/res/layout/emoji_keyboard_page.xml b/java/res/layout/emoji_keyboard_page.xml index e0b752b32..0d1086171 100644 --- a/java/res/layout/emoji_keyboard_page.xml +++ b/java/res/layout/emoji_keyboard_page.xml @@ -18,16 +18,9 @@ */ --> -<com.android.inputmethod.keyboard.internal.ScrollViewWithNotifier +<com.android.inputmethod.keyboard.emoji.EmojiPageKeyboardView xmlns:android="http://schemas.android.com/apk/res/android" - android:id="@+id/emoji_keyboard_scroller" - android:clipToPadding="false" - android:layout_width="match_parent" - android:layout_height="match_parent" -> - <com.android.inputmethod.keyboard.internal.ScrollKeyboardView - android:id="@+id/emoji_keyboard_page" - android:layoutDirection="ltr" - android:layout_width="wrap_content" - android:layout_height="wrap_content" /> -</com.android.inputmethod.keyboard.internal.ScrollViewWithNotifier> + android:id="@+id/emoji_keyboard_page" + android:layoutDirection="ltr" + android:layout_width="wrap_content" + android:layout_height="wrap_content" /> diff --git a/java/res/layout/emoji_keyboard_tab_icon.xml b/java/res/layout/emoji_keyboard_tab_icon.xml index 1609f6a26..15f9c3a3e 100644 --- a/java/res/layout/emoji_keyboard_tab_icon.xml +++ b/java/res/layout/emoji_keyboard_tab_icon.xml @@ -18,10 +18,16 @@ */ --> +<!-- Note: contentDescription will be added programatically in {@link EmojiPalettesView}. --> +<!-- Provide audio and haptic feedback by ourselves based on the keyboard settings. + We just need to ignore the system's audio and haptic feedback settings. --> <ImageView xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="0dip" android:layout_weight="1.0" android:layout_height="wrap_content" android:gravity="center" android:scaleType="center" + android:contentDescription="@null" + android:hapticFeedbackEnabled="false" + android:soundEffectsEnabled="false" /> diff --git a/java/res/layout/emoji_keyboard_tab_label.xml b/java/res/layout/emoji_keyboard_tab_label.xml deleted file mode 100644 index 62c552dd8..000000000 --- a/java/res/layout/emoji_keyboard_tab_label.xml +++ /dev/null @@ -1,26 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2013, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<TextView xmlns:android="http://schemas.android.com/apk/res/android" - android:layout_width="0dip" - android:layout_weight="1.0" - android:layout_height="wrap_content" - android:gravity="center" -/> diff --git a/java/res/layout/emoji_palettes_view.xml b/java/res/layout/emoji_palettes_view.xml index 1c6da90ba..9ff090aad 100644 --- a/java/res/layout/emoji_palettes_view.xml +++ b/java/res/layout/emoji_palettes_view.xml @@ -18,7 +18,7 @@ */ --> -<com.android.inputmethod.keyboard.EmojiPalettesView +<com.android.inputmethod.keyboard.emoji.EmojiPalettesView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/emoji_keyboard_view" android:orientation="vertical" @@ -29,7 +29,7 @@ <LinearLayout android:orientation="horizontal" android:layout_width="match_parent" - android:layout_height="@dimen/suggestions_strip_height" + android:layout_height="@dimen/config_suggestions_strip_height" > <TabHost android:id="@+id/emoji_category_tabhost" @@ -41,11 +41,7 @@ android:id="@android:id/tabs" android:layout_width="match_parent" android:layout_height="match_parent" - android:background="@drawable/tab_selected" - android:divider="@null" - android:tabStripEnabled="true" - android:tabStripLeft="@drawable/tab_unselected" - android:tabStripRight="@drawable/tab_unselected" /> + android:divider="@null" /> <FrameLayout android:id="@android:id/tabcontent" android:layout_width="0dip" @@ -65,23 +61,26 @@ android:layout_width="2dip" android:layout_height="match_parent" android:background="@drawable/suggestions_strip_divider" /> + <!-- TODO: Implement KeyView and replace this. --> + <!-- Provide audio and haptic feedback by ourselves based on the keyboard settings. + We just need to ignore the system's audio and haptic feedback settings. --> <ImageButton android:id="@+id/emoji_keyboard_delete" android:layout_width="0dip" android:layout_weight="12.5" android:layout_height="match_parent" - android:background="@color/emoji_key_background_color" - android:src="@drawable/sym_keyboard_delete_holo_dark" /> + android:hapticFeedbackEnabled="false" + android:soundEffectsEnabled="false" + android:contentDescription="@string/spoken_description_delete" /> </LinearLayout> <android.support.v4.view.ViewPager android:id="@+id/emoji_keyboard_pager" android:layout_width="match_parent" android:layout_height="wrap_content" /> - <com.android.inputmethod.keyboard.EmojiCategoryPageIndicatorView + <com.android.inputmethod.keyboard.emoji.EmojiCategoryPageIndicatorView android:id="@+id/emoji_category_page_id_view" android:layout_width="match_parent" - android:layout_height="wrap_content" - android:background="@color/emoji_category_page_id_view_background" /> + android:layout_height="2dip" /> <LinearLayout android:id="@+id/emoji_action_bar" android:orientation="horizontal" @@ -89,22 +88,47 @@ android:layout_height="0dip" android:layout_weight="1" > - <ImageButton - android:id="@+id/emoji_keyboard_alphabet" + <!-- TODO: Implement a KeyView and replace this. --> + <!-- Provide audio and haptic feedback by ourselves based on the keyboard settings. + We just need to ignore the system's audio and haptic feedback settings. --> + <TextView + android:id="@+id/emoji_keyboard_alphabet_left" android:layout_width="0dip" android:layout_weight="0.15" + android:gravity="center" android:layout_height="match_parent" - android:src="@drawable/ic_ime_switcher_dark" /> - <ImageButton + android:hapticFeedbackEnabled="false" + android:soundEffectsEnabled="false" /> + <!-- TODO: Implement KeyView and replace this. --> + <!-- Provide audio and haptic feedback by ourselves based on the keyboard settings. + We just need to ignore the system's audio and haptic feedback settings. --> + <RelativeLayout android:id="@+id/emoji_keyboard_space" android:layout_width="0dip" android:layout_weight="0.70" - android:layout_height="match_parent" /> - <ImageButton - android:id="@+id/emoji_keyboard_alphabet2" + android:layout_height="match_parent" + android:hapticFeedbackEnabled="false" + android:soundEffectsEnabled="false" + android:contentDescription="@string/spoken_description_space"> + <!-- WORKAROUND: Show the spacebar icon as a bacground of this View. --> + <View + android:id="@+id/emoji_keyboard_space_icon" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_marginLeft="12dp" + android:layout_marginRight="12dp" + android:layout_centerInParent="true" /> + </RelativeLayout> + <!-- TODO: Implement KeyView and replace this. --> + <!-- Provide audio and haptic feedback by ourselves based on the keyboard settings. + We just need to ignore the system's audio and haptic feedback settings. --> + <TextView + android:id="@+id/emoji_keyboard_alphabet_right" android:layout_width="0dip" android:layout_weight="0.15" + android:gravity="center" android:layout_height="match_parent" - android:src="@drawable/ic_ime_switcher_dark" /> + android:hapticFeedbackEnabled="false" + android:soundEffectsEnabled="false" /> </LinearLayout> -</com.android.inputmethod.keyboard.EmojiPalettesView> +</com.android.inputmethod.keyboard.emoji.EmojiPalettesView> diff --git a/java/res/layout/hint_add_to_dictionary.xml b/java/res/layout/hint_add_to_dictionary.xml deleted file mode 100644 index 68a9faf19..000000000 --- a/java/res/layout/hint_add_to_dictionary.xml +++ /dev/null @@ -1,36 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2012, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<!-- This is derived from suggestion_word.xml without minWidth attribute and padding --> -<TextView - xmlns:android="http://schemas.android.com/apk/res/android" - android:layout_width="match_parent" - android:layout_height="match_parent" - android:textSize="@dimen/suggestion_text_size" - android:gravity="center" - android:paddingLeft="0dp" - android:paddingTop="0dp" - android:paddingRight="0dp" - android:paddingBottom="0dp" - android:focusable="false" - android:clickable="false" - android:singleLine="true" - android:ellipsize="none" - style="?attr/suggestionWordStyle" /> diff --git a/java/res/layout/input_view.xml b/java/res/layout/input_view.xml index 1e7a3844e..ff0b403d1 100644 --- a/java/res/layout/input_view.xml +++ b/java/res/layout/input_view.xml @@ -41,10 +41,8 @@ android:id="@+id/suggestion_strip_view" android:layoutDirection="ltr" android:layout_width="match_parent" - android:layout_height="@dimen/suggestions_strip_height" + android:layout_height="@dimen/config_suggestions_strip_height" android:gravity="center_vertical" - android:paddingRight="@dimen/suggestions_strip_padding" - android:paddingLeft="@dimen/suggestions_strip_padding" style="?attr/suggestionStripViewStyle" /> <!-- To ensure that key preview popup is correctly placed when the current system locale is diff --git a/java/res/layout/key_preview_gb.xml b/java/res/layout/key_preview_gb.xml deleted file mode 100644 index 2f2a321a3..000000000 --- a/java/res/layout/key_preview_gb.xml +++ /dev/null @@ -1,27 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2010, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<TextView xmlns:android="http://schemas.android.com/apk/res/android" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:background="@drawable/keyboard_key_feedback_gb" - android:minWidth="32dp" - android:gravity="center" -/> diff --git a/java/res/layout/key_preview_ics.xml b/java/res/layout/key_preview_ics.xml deleted file mode 100644 index 33b6947ef..000000000 --- a/java/res/layout/key_preview_ics.xml +++ /dev/null @@ -1,27 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2013, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<TextView xmlns:android="http://schemas.android.com/apk/res/android" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:background="@drawable/keyboard_key_feedback_ics" - android:minWidth="32dp" - android:gravity="center" -/> diff --git a/java/res/layout/key_preview_klp.xml b/java/res/layout/key_preview_klp.xml deleted file mode 100644 index 160aeb9a9..000000000 --- a/java/res/layout/key_preview_klp.xml +++ /dev/null @@ -1,27 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2013, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<TextView xmlns:android="http://schemas.android.com/apk/res/android" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:background="@drawable/keyboard_key_feedback_klp" - android:minWidth="32dp" - android:gravity="center" -/> diff --git a/java/res/layout/more_keys_keyboard.xml b/java/res/layout/more_keys_keyboard.xml index 6637117e0..f3795afdc 100644 --- a/java/res/layout/more_keys_keyboard.xml +++ b/java/res/layout/more_keys_keyboard.xml @@ -22,11 +22,9 @@ xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:orientation="horizontal" - style="?attr/moreKeysKeyboardContainerStyle" + android:orientation="vertical" > <com.android.inputmethod.keyboard.MoreKeysKeyboardView - xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" android:id="@+id/more_keys_keyboard_view" android:layout_width="wrap_content" android:layout_height="wrap_content" /> diff --git a/java/res/layout/more_suggestions.xml b/java/res/layout/more_suggestions.xml index 8659f0761..0869992c9 100644 --- a/java/res/layout/more_suggestions.xml +++ b/java/res/layout/more_suggestions.xml @@ -22,16 +22,15 @@ xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:orientation="horizontal" - style="?attr/moreKeysKeyboardContainerStyle" + android:orientation="vertical" > <com.android.inputmethod.latin.suggestions.MoreSuggestionsView xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" android:id="@+id/more_suggestions_view" android:layout_width="wrap_content" android:layout_height="wrap_content" - latin:keyLetterSize="@dimen/suggestion_text_size" - latin:keyLabelSize="@dimen/suggestion_text_size" - latin:keyHintLetterRatio="@fraction/more_suggestions_info_ratio" + latin:keyLetterSize="@dimen/config_suggestion_text_size" + latin:keyLabelSize="@dimen/config_suggestion_text_size" + latin:keyHintLetterRatio="@fraction/config_more_suggestions_info_ratio" latin:keyHintLetterColor="@android:color/white" /> </LinearLayout> diff --git a/java/res/layout/research_feedback_activity.xml b/java/res/layout/research_feedback_activity.xml deleted file mode 100644 index a6b8b8a43..000000000 --- a/java/res/layout/research_feedback_activity.xml +++ /dev/null @@ -1,31 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- Copyright (C) 2012 The Android Open Source Project - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---> - -<com.android.inputmethod.research.FeedbackLayout - xmlns:android="http://schemas.android.com/apk/res/android" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:orientation="vertical" - android:id="@+id/research_feedback_layout" -> - - <fragment - android:id="@+id/research_feedback_fragment" - android:name="com.android.inputmethod.research.FeedbackFragment" - android:layout_width="match_parent" - android:layout_height="wrap_content" - /> -</com.android.inputmethod.research.FeedbackLayout> diff --git a/java/res/layout/research_feedback_fragment_layout.xml b/java/res/layout/research_feedback_fragment_layout.xml deleted file mode 100644 index 505a1e8d9..000000000 --- a/java/res/layout/research_feedback_fragment_layout.xml +++ /dev/null @@ -1,123 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- Copyright (C) 2012 The Android Open Source Project - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---> - -<!-- Adapted from frameworks/base/core/res/res/layout/alert_dialog_holo.xml. We - want a dialog, but it must be its own activity so we can launch the soft - keyboard on it. A regular dialog will not work since it would be launched from - the IME. --> -<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"> - <LinearLayout - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_marginStart="8dip" - android:layout_marginEnd="8dip" - android:orientation="vertical"> - <LinearLayout - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:orientation="vertical"> - <View android:layout_width="match_parent" - android:layout_height="2dip" - android:visibility="gone" - android:background="@android:color/holo_blue_light" /> - <TextView - style="?android:attr/windowTitleStyle" - android:singleLine="true" - android:ellipsize="end" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:minHeight="64dip" - android:layout_marginLeft="16dip" - android:layout_marginRight="16dip" - android:gravity="center_vertical|left" - android:text="@string/research_feedback_dialog_title" /> - <View - android:layout_width="match_parent" - android:layout_height="2dip" - android:background="@android:color/holo_blue_light" /> - </LinearLayout> - - <EditText - android:id="@+id/research_feedback_contents" - android:layout_height="wrap_content" - android:layout_width="match_parent" - android:layout_gravity="fill_horizontal|center_vertical" - android:layout_marginLeft="8dip" - android:layout_marginRight="8dip" - android:layout_marginBottom="8dip" - android:layout_marginTop="8dip" - android:minLines="2" - android:scrollbars="vertical" - android:hint="@string/research_feedback_hint" - android:inputType="textMultiLine|textCapSentences"> - <requestFocus /> - </EditText> - <CheckBox - android:id="@+id/research_feedback_include_account_name" - android:layout_height="wrap_content" - android:layout_width="match_parent" - android:layout_marginLeft="16dip" - android:layout_marginRight="16dip" - android:layout_marginBottom="8dip" - android:checked="false" - android:text="@string/research_feedback_include_account_name_label" /> - <CheckBox - android:id="@+id/research_feedback_include_recording_checkbox" - android:layout_height="wrap_content" - android:layout_width="match_parent" - android:layout_marginLeft="16dip" - android:layout_marginRight="16dip" - android:layout_marginBottom="8dip" - android:checked="false" - android:text="@string/research_feedback_include_recording_label" /> - <LinearLayout - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:orientation="vertical" - android:divider="?android:attr/dividerHorizontal" - android:showDividers="beginning" - android:dividerPadding="0dip"> - <LinearLayout - style="?android:attr/buttonBarStyle" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:orientation="horizontal" - android:layoutDirection="locale" - android:measureWithLargestChild="true"> - <Button - android:id="@+id/research_feedback_cancel_button" - android:layout_width="wrap_content" - android:layout_gravity="left" - android:layout_weight="1" - android:maxLines="2" - style="?android:attr/buttonBarButtonStyle" - android:textSize="14sp" - android:text="@string/research_feedback_cancel" - android:layout_height="wrap_content" /> - <Button - android:id="@+id/research_feedback_send_button" - android:layout_width="wrap_content" - android:layout_gravity="right" - android:layout_weight="1" - android:maxLines="2" - style="?android:attr/buttonBarButtonStyle" - android:textSize="14sp" - android:text="@string/research_feedback_send" - android:layout_height="wrap_content" /> - </LinearLayout> - </LinearLayout> - </LinearLayout> -</ScrollView> diff --git a/java/res/layout/research_feedback_layout.xml b/java/res/layout/research_feedback_layout.xml deleted file mode 100644 index bacd19101..000000000 --- a/java/res/layout/research_feedback_layout.xml +++ /dev/null @@ -1,50 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- Copyright (C) 2012 The Android Open Source Project - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---> - -<LinearLayout - xmlns:android="http://schemas.android.com/apk/res/android" - android:layout_width="fill_parent" - android:layout_height="fill_parent" - android:orientation="vertical" -> - - <EditText - android:id="@+id/research_feedback_contents" - android:layout_height="wrap_content" - android:layout_width="match_parent" - android:layout_gravity="fill_horizontal|center_vertical" - android:layout_marginLeft="8dip" - android:layout_marginRight="8dip" - android:layout_marginBottom="8dip" - android:layout_marginTop="8dip" - android:lines="2" - android:hint="@string/research_feedback_hint" - android:inputType="textMultiLine" - android:imeOptions="flagNoFullscreen" - android:focusable="true" - > - <requestFocus /> - </EditText> - - <CheckBox - android:id="@+id/research_feedback_include_history" - android:layout_height="wrap_content" - android:layout_width="match_parent" - android:layout_marginBottom="8dip" - android:checked="true" - android:text="@string/research_feedback_include_history_label" - /> -</LinearLayout> diff --git a/java/res/layout/seek_bar_dialog.xml b/java/res/layout/seek_bar_dialog.xml index a47e9a038..e723ad9bb 100644 --- a/java/res/layout/seek_bar_dialog.xml +++ b/java/res/layout/seek_bar_dialog.xml @@ -33,7 +33,7 @@ <TextView android:id="@+id/seek_bar_dialog_value" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:textSize="20dp"/> + android:textSize="20sp"/> </LinearLayout> <SeekBar android:id="@+id/seek_bar_dialog_bar" diff --git a/java/res/layout/setup_steps_title.xml b/java/res/layout/setup_steps_title.xml index e3694bfe0..9ee8693f8 100644 --- a/java/res/layout/setup_steps_title.xml +++ b/java/res/layout/setup_steps_title.xml @@ -21,7 +21,5 @@ <merge xmlns:android="http://schemas.android.com/apk/res/android"> <TextView android:id="@+id/setup_title" - style="@style/setupTitleStyle" - android:layout_alignParentLeft="true" - android:layout_alignParentTop="true" /> + style="@style/setupTitleStyle" /> </merge> diff --git a/java/res/layout/setup_welcome_title.xml b/java/res/layout/setup_welcome_title.xml index af7053a37..2c3b48919 100644 --- a/java/res/layout/setup_welcome_title.xml +++ b/java/res/layout/setup_welcome_title.xml @@ -21,9 +21,7 @@ <merge xmlns:android="http://schemas.android.com/apk/res/android"> <TextView android:id="@+id/setup_welcome_title" - style="@style/setupTitleStyle" - android:layout_alignParentLeft="true" - android:layout_alignParentTop="true" /> + style="@style/setupTitleStyle" /> <TextView android:id="@+id/setup_welcome_description" android:text="@string/setup_welcome_additional_description" diff --git a/java/res/layout/suggestion_divider.xml b/java/res/layout/suggestion_divider.xml index a8b78c082..563599d82 100644 --- a/java/res/layout/suggestion_divider.xml +++ b/java/res/layout/suggestion_divider.xml @@ -18,10 +18,17 @@ */ --> +<!-- Provide audio and haptic feedback by ourselves based on the keyboard settings. + We just need to ignore the system's audio and haptic feedback settings. --> <ImageView xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="wrap_content" android:layout_height="match_parent" - android:src="@drawable/suggestions_strip_divider" android:padding="0dp" - android:gravity="center" /> + android:gravity="center" + android:src="@drawable/suggestions_strip_divider" + android:contentDescription="@null" + android:clickable="false" + android:longClickable="false" + android:hapticFeedbackEnabled="false" + android:soundEffectsEnabled="false" /> diff --git a/java/res/layout/suggestion_info.xml b/java/res/layout/suggestion_info.xml deleted file mode 100644 index 0aa26000d..000000000 --- a/java/res/layout/suggestion_info.xml +++ /dev/null @@ -1,27 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2011, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<TextView - xmlns:android="http://schemas.android.com/apk/res/android" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:textSize="6dp" - android:textColor="@android:color/white" - style="?attr/suggestionWordStyle" /> diff --git a/java/res/layout/suggestion_word.xml b/java/res/layout/suggestion_word.xml deleted file mode 100644 index c82a13c99..000000000 --- a/java/res/layout/suggestion_word.xml +++ /dev/null @@ -1,39 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2011, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<!-- Provide a haptic feedback by ourselves based on the keyboard settings. - We just need to ignore the system's haptic feedback settings. --> -<TextView - xmlns:android="http://schemas.android.com/apk/res/android" - android:layout_width="match_parent" - android:layout_height="match_parent" - android:minWidth="@dimen/suggestion_min_width" - android:textSize="@dimen/suggestion_text_size" - android:gravity="center" - android:paddingLeft="@dimen/suggestion_padding" - android:paddingTop="0dp" - android:paddingRight="@dimen/suggestion_padding" - android:paddingBottom="0dp" - android:hapticFeedbackEnabled="false" - android:focusable="false" - android:clickable="false" - android:singleLine="true" - android:ellipsize="none" - style="?attr/suggestionWordStyle" /> diff --git a/java/res/layout/suggestions_strip.xml b/java/res/layout/suggestions_strip.xml index cbf31e6dc..489477990 100644 --- a/java/res/layout/suggestions_strip.xml +++ b/java/res/layout/suggestions_strip.xml @@ -19,12 +19,69 @@ --> <merge - xmlns:android="http://schemas.android.com/apk/res/android" - xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" -> + xmlns:android="http://schemas.android.com/apk/res/android"> + <!-- Provide audio and haptic feedback by ourselves based on the keyboard settings. + We just need to ignore the system's audio and haptic feedback settings. --> <LinearLayout android:id="@+id/suggestions_strip" android:orientation="horizontal" android:layout_width="match_parent" - android:layout_height="match_parent" /> + android:layout_height="match_parent" + android:layout_marginLeft="@dimen/config_suggestions_strip_horizontal_margin" + android:layout_marginRight="@dimen/config_suggestions_strip_horizontal_margin" + android:hapticFeedbackEnabled="false" + android:soundEffectsEnabled="false" /> + <!-- Provide audio and haptic feedback by ourselves based on the keyboard settings. + We just need to ignore the system's audio and haptic feedback settings. --> + <LinearLayout + android:id="@+id/add_to_dictionary_strip" + android:orientation="horizontal" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:layout_marginLeft="@dimen/config_suggestions_strip_horizontal_margin" + android:layout_marginRight="@dimen/config_suggestions_strip_horizontal_margin" + android:hapticFeedbackEnabled="false" + android:soundEffectsEnabled="false"> + <TextView + android:id="@+id/word_to_save" + android:layout_width="match_parent" + android:layout_height="match_parent" + style="?attr/suggestionWordStyle" /> + <include + layout="@layout/suggestion_divider" /> + <TextView + android:id="@+id/hint_add_to_dictionary" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:textAlignment="viewStart" + style="?attr/suggestionWordStyle" /> + </LinearLayout> + <!-- Provide audio and haptic feedback by ourselves based on the keyboard settings. + We just need to ignore the system's audio and haptic feedback settings. --> + <LinearLayout + android:id="@+id/important_notice_strip" + android:orientation="horizontal" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:layout_marginLeft="@dimen/config_suggestions_strip_horizontal_margin" + android:layout_marginRight="@dimen/config_suggestions_strip_horizontal_margin" + android:hapticFeedbackEnabled="false" + android:soundEffectsEnabled="false" > + <TextView + android:id="@+id/important_notice_title" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:padding="6sp" + android:textSize="16sp" + style="?attr/suggestionWordStyle" /> + </LinearLayout> + <ImageButton + android:id="@+id/suggestions_strip_voice_key" + android:layout_width="@dimen/config_suggestions_strip_edge_key_width" + android:layout_height="fill_parent" + android:layout_alignParentEnd="true" + android:layout_alignParentRight="true" + android:layout_centerVertical="true" + android:contentDescription="@string/spoken_description_mic" + style="?attr/suggestionWordStyle" /> </merge> diff --git a/java/res/layout/user_dictionary_add_word.xml b/java/res/layout/user_dictionary_add_word.xml index bbf9b1b5b..615fde589 100644 --- a/java/res/layout/user_dictionary_add_word.xml +++ b/java/res/layout/user_dictionary_add_word.xml @@ -52,48 +52,39 @@ android:hint="@string/user_dict_settings_add_word_hint" android:imeOptions="flagNoFullscreen" android:inputType="textNoSuggestions" - android:maxLength="@integer/user_dictionary_max_word_length" > + android:maxLength="@integer/config_user_dictionary_max_word_length" > <requestFocus /> </EditText> <LinearLayout + style="?android:attr/buttonBarStyle" android:layout_width="match_parent" android:layout_height="wrap_content" - android:divider="?android:attr/dividerHorizontal" - android:dividerPadding="0dip" - android:orientation="vertical" - android:showDividers="beginning" > + android:measureWithLargestChild="true" + android:orientation="horizontal" > - <LinearLayout - style="?android:attr/buttonBarStyle" - android:layout_width="match_parent" + <Button + style="?android:attr/buttonBarButtonStyle" + android:layout_width="0dip" android:layout_height="wrap_content" - android:measureWithLargestChild="true" - android:orientation="horizontal" > - - <Button - style="?android:attr/buttonBarButtonStyle" - android:layout_width="0dip" - android:layout_height="wrap_content" - android:layout_gravity="start" - android:layout_weight="1" - android:maxLines="2" - android:onClick="onClickCancel" - android:text="@string/cancel" - android:textSize="14sp" /> + android:layout_gravity="start" + android:layout_weight="1" + android:maxLines="2" + android:onClick="onClickCancel" + android:text="@string/cancel" + android:textSize="14sp" /> - <Button - style="?android:attr/buttonBarButtonStyle" - android:layout_width="0dip" - android:layout_height="wrap_content" - android:layout_gravity="end" - android:layout_weight="1" - android:maxLines="2" - android:onClick="onClickConfirm" - android:text="@string/user_dict_settings_add_dialog_confirm" - android:textSize="14sp" /> - </LinearLayout> + <Button + style="?android:attr/buttonBarButtonStyle" + android:layout_width="0dip" + android:layout_height="wrap_content" + android:layout_gravity="end" + android:layout_weight="1" + android:maxLines="2" + android:onClick="onClickConfirm" + android:text="@string/user_dict_settings_add_dialog_confirm" + android:textSize="14sp" /> </LinearLayout> </LinearLayout>
\ No newline at end of file diff --git a/java/res/layout/user_dictionary_add_word_fullscreen.xml b/java/res/layout/user_dictionary_add_word_fullscreen.xml index 219485b66..9bcb189b4 100644 --- a/java/res/layout/user_dictionary_add_word_fullscreen.xml +++ b/java/res/layout/user_dictionary_add_word_fullscreen.xml @@ -30,7 +30,7 @@ android:hint="@string/user_dict_settings_add_word_hint" android:imeOptions="flagNoFullscreen" android:inputType="textNoSuggestions" - android:maxLength="@integer/user_dictionary_max_word_length" > + android:maxLength="@integer/config_user_dictionary_max_word_length" > <requestFocus /> </EditText> @@ -61,7 +61,7 @@ android:hint="@string/user_dict_settings_add_shortcut_hint" android:imeOptions="flagNoFullscreen" android:inputType="textNoSuggestions" - android:maxLength="@integer/user_dictionary_max_word_length" /> + android:maxLength="@integer/config_user_dictionary_max_word_length" /> <TextView android:id="@+id/user_dictionary_add_locale_label" diff --git a/java/res/layout/user_dictionary_item.xml b/java/res/layout/user_dictionary_item.xml index 56bad7743..b8d48b56d 100644 --- a/java/res/layout/user_dictionary_item.xml +++ b/java/res/layout/user_dictionary_item.xml @@ -19,10 +19,11 @@ android:background="?android:attr/selectableItemBackground" android:gravity="center_vertical" android:minHeight="?android:attr/listPreferredItemHeight" - android:paddingEnd="?android:attr/scrollbarSize" > + android:paddingEnd="?android:attr/scrollbarSize" + android:baselineAligned="false" > <RelativeLayout - android:layout_width="wrap_content" + android:layout_width="0dp" android:layout_height="wrap_content" android:padding="6dip" android:layout_weight="1" > |