diff options
author | Jin Cao <jinyan@google.com> | 2014-08-10 13:07:11 -0700 |
---|---|---|
committer | Jin Cao <jinyan@google.com> | 2014-08-10 13:07:11 -0700 |
commit | a21fd887528a3b985f71decb2a19c917c2fcbd55 (patch) | |
tree | 7b24c28ef97ad3719bb6376b6d88581fc167df08 /res | |
parent | 58a23da6e0d6531316e53ecf2e7a530ec4c9f17c (diff) | |
download | chips-a21fd887528a3b985f71decb2a19c917c2fcbd55.tar.gz |
[Quantum chips] code cleanup and restyling
Cleaned up the variable placements in RecipientEditTextView
and removed some outdated functionality.
Updated the style for alternate/single recipient dropdown
to redline.
b/16851158
Change-Id: I0829be08cbf6d603c4b029aec820937379c5dad2
Diffstat (limited to 'res')
18 files changed, 18 insertions, 23 deletions
diff --git a/res/drawable-hdpi/chip_delete.png b/res/drawable-hdpi/chip_delete.png Binary files differdeleted file mode 100644 index feccc69..0000000 --- a/res/drawable-hdpi/chip_delete.png +++ /dev/null diff --git a/res/drawable-hdpi/chips_popup_background.9.png b/res/drawable-hdpi/chips_popup_background.9.png Binary files differdeleted file mode 100644 index 060ffad..0000000 --- a/res/drawable-hdpi/chips_popup_background.9.png +++ /dev/null diff --git a/res/drawable-hdpi/ic_cancel_wht_24dp.png b/res/drawable-hdpi/ic_cancel_wht_24dp.png Binary files differnew file mode 100644 index 0000000..7dac7b0 --- /dev/null +++ b/res/drawable-hdpi/ic_cancel_wht_24dp.png diff --git a/res/drawable-mdpi/chip_delete.png b/res/drawable-mdpi/chip_delete.png Binary files differdeleted file mode 100644 index 294db89..0000000 --- a/res/drawable-mdpi/chip_delete.png +++ /dev/null diff --git a/res/drawable-mdpi/chips_popup_background.9.png b/res/drawable-mdpi/chips_popup_background.9.png Binary files differdeleted file mode 100644 index 2989590..0000000 --- a/res/drawable-mdpi/chips_popup_background.9.png +++ /dev/null diff --git a/res/drawable-mdpi/ic_cancel_wht_24dp.png b/res/drawable-mdpi/ic_cancel_wht_24dp.png Binary files differnew file mode 100644 index 0000000..48343c9 --- /dev/null +++ b/res/drawable-mdpi/ic_cancel_wht_24dp.png diff --git a/res/drawable-xhdpi/chip_delete.png b/res/drawable-xhdpi/chip_delete.png Binary files differdeleted file mode 100644 index bed6d67..0000000 --- a/res/drawable-xhdpi/chip_delete.png +++ /dev/null diff --git a/res/drawable-xhdpi/chips_popup_background.9.png b/res/drawable-xhdpi/chips_popup_background.9.png Binary files differdeleted file mode 100644 index f8b809a..0000000 --- a/res/drawable-xhdpi/chips_popup_background.9.png +++ /dev/null diff --git a/res/drawable-xhdpi/ic_cancel_wht_24dp.png b/res/drawable-xhdpi/ic_cancel_wht_24dp.png Binary files differnew file mode 100644 index 0000000..3dc3615 --- /dev/null +++ b/res/drawable-xhdpi/ic_cancel_wht_24dp.png diff --git a/res/drawable-xxhdpi/chip_delete.png b/res/drawable-xxhdpi/chip_delete.png Binary files differdeleted file mode 100644 index f6d3196..0000000 --- a/res/drawable-xxhdpi/chip_delete.png +++ /dev/null diff --git a/res/drawable-xxhdpi/chips_popup_background.9.png b/res/drawable-xxhdpi/chips_popup_background.9.png Binary files differdeleted file mode 100644 index bb4f281..0000000 --- a/res/drawable-xxhdpi/chips_popup_background.9.png +++ /dev/null diff --git a/res/drawable-xxhdpi/ic_cancel_wht_24dp.png b/res/drawable-xxhdpi/ic_cancel_wht_24dp.png Binary files differnew file mode 100644 index 0000000..2ba1978 --- /dev/null +++ b/res/drawable-xxhdpi/ic_cancel_wht_24dp.png diff --git a/res/drawable-xxxhdpi/ic_cancel_wht_24dp.png b/res/drawable-xxxhdpi/ic_cancel_wht_24dp.png Binary files differnew file mode 100644 index 0000000..89ad2b5 --- /dev/null +++ b/res/drawable-xxxhdpi/ic_cancel_wht_24dp.png diff --git a/res/layout/chips_recipient_dropdown_item.xml b/res/layout/chips_recipient_dropdown_item.xml index a0f33d6..ffb019b 100644 --- a/res/layout/chips_recipient_dropdown_item.xml +++ b/res/layout/chips_recipient_dropdown_item.xml @@ -18,7 +18,7 @@ android:layout_width="match_parent" android:layout_height="@dimen/chip_dropdown_height" android:background="@drawable/chips_dropdown_background" - android:padding="16dp"> + android:padding="12dp"> <com.android.ex.chips.CircularImageView style="@style/ChipStartIconStyle" /> @@ -30,6 +30,6 @@ </LinearLayout> - <com.android.ex.chips.CircularImageView style="@style/ChipDeleteIconStyle" /> + <ImageView style="@style/ChipDeleteIconStyle" /> </LinearLayout>
\ No newline at end of file diff --git a/res/values-sw600dp/styles.xml b/res/values-sw600dp/styles.xml index 06e7608..5ca5ad9 100644 --- a/res/values-sw600dp/styles.xml +++ b/res/values-sw600dp/styles.xml @@ -15,16 +15,7 @@ --> <resources xmlns:tools="http://schemas.android.com/tools" xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2"> - <style name="RecipientEditTextView" parent="@android:attr/autoCompleteTextViewStyle"> - <item name="android:paddingLeft">8dip</item> - <item name="android:paddingRight">4dip</item> - <item name="android:inputType">textEmailAddress|textMultiLine</item> + <style name="RecipientEditTextView" parent="@style/RecipientEditTextViewBase"> <item name="android:imeOptions">actionNext</item> - <item name="android:textAppearance">?android:attr/textAppearanceMedium</item> - <item name="android:background">@null</item> - <item name="android:layout_height">wrap_content</item> - <item name="android:layout_width">match_parent</item> - <item name="android:textAlignment" tools:ignore="NewApi">viewStart</item> - <item name="android:textDirection" tools:ignore="NewApi">locale</item> </style> </resources> diff --git a/res/values-v17/styles.xml b/res/values-v17/styles.xml index 53b5634..fd47b97 100644 --- a/res/values-v17/styles.xml +++ b/res/values-v17/styles.xml @@ -37,6 +37,6 @@ </style> <style name="ChipDeleteIconStyle" parent="@style/ChipDeleteIconBaseStyle"> - <item name="android:paddingStart">20dp</item> + <item name="android:paddingStart">8dp</item> </style> </resources> diff --git a/res/values/dimen.xml b/res/values/dimen.xml index 6cb56c6..f2b71df 100644 --- a/res/values/dimen.xml +++ b/res/values/dimen.xml @@ -23,11 +23,11 @@ <dimen name="chip_padding">8dp</dimen> <dimen name="chip_height">32dp</dimen> <dimen name="chip_text_size">14sp</dimen> - <dimen name="line_spacing_extra">4dip</dimen> + <dimen name="line_spacing_extra">4dp</dimen> <integer name="chips_max_lines">-1</integer> <!-- dropdown --> - <dimen name="chip_icon_margin_end">16dp</dimen> + <dimen name="chip_icon_margin_end">12dp</dimen> <dimen name="chip_dropdown_height">72dp</dimen> <dimen name="chip_custom_divider_height">0.5dp</dimen> <!-- autocomplete dropdown --> diff --git a/res/values/styles.xml b/res/values/styles.xml index 37124b3..a528934 100644 --- a/res/values/styles.xml +++ b/res/values/styles.xml @@ -15,21 +15,23 @@ --> <resources xmlns:tools="http://schemas.android.com/tools" xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2"> - <style name="RecipientEditTextView" parent="@android:attr/autoCompleteTextViewStyle"> + <style name="RecipientEditTextViewBase" parent="@android:attr/autoCompleteTextViewStyle"> <item name="android:layout_width">match_parent</item> <item name="android:layout_height">wrap_content</item> <item name="android:background">@null</item> - <item name="android:dropDownWidth">match_parent</item> - <item name="android:imeOptions">actionNext|flagNoFullscreen</item> <item name="android:inputType">textEmailAddress|textMultiLine</item> - <item name="android:lineSpacingExtra">@dimen/line_spacing_extra</item> <item name="android:minHeight">@dimen/chip_height</item> - <item name="android:popupBackground">@drawable/chips_popup_background</item> + <item name="android:lineSpacingExtra">@dimen/line_spacing_extra</item> + <item name="android:popupBackground">@null</item> <item name="android:textAlignment" tools:ignore="NewApi">viewStart</item> <item name="android:textAppearance">?android:attr/textAppearanceMedium</item> <item name="android:textDirection" tools:ignore="NewApi">locale</item> </style> + <style name="RecipientEditTextView" parent="@style/RecipientEditTextViewBase"> + <item name="android:imeOptions">actionNext|flagNoFullscreen</item> + </style> + <style name="ChipAutocompleteWrapperStyle"> <item name="android:paddingLeft">@dimen/chip_wrapper_start_padding</item> <item name="android:paddingTop">@dimen/chip_wrapper_top_padding</item> @@ -78,6 +80,7 @@ <item name="android:id">@android:id/icon</item> <item name="android:layout_width">40dp</item> <item name="android:layout_height">40dp</item> + <item name="android:layout_gravity">center_vertical</item> <item name="android:contentDescription">@null</item> </style> @@ -91,13 +94,14 @@ <style name="ChipDeleteIconBaseStyle"> <item name="android:id">@android:id/icon1</item> - <item name="android:layout_width">40dp</item> - <item name="android:layout_height">40dp</item> + <item name="android:layout_width">36dp</item> + <item name="android:layout_height">48dp</item> + <item name="android:layout_gravity">center_vertical</item> <item name="android:paddingTop">10dp</item> <item name="android:paddingBottom">10dp</item> </style> <style name="ChipDeleteIconStyle" parent="@style/ChipDeleteIconBaseStyle"> - <item name="android:paddingLeft">20dp</item> + <item name="android:paddingLeft">8dp</item> </style> </resources> |