From 2f5b5ea433a1dd4328dfdf24d1f437a8e5a31a6e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timi=20Rautam=C3=A4ki?= Date: Sun, 11 Jul 2021 20:40:27 +0200 Subject: Dialer: improve search bar * Make background color lighter * Update border radius * Update ripple to follow border radius * Remove the background color, use same as activity * Update the back-icon color to white/black for consistency Change-Id: I648a2bd0da47fec99d8a8457c70451e77ed9f8be --- .../search_bar_background_rounded_corners.xml | 17 ++++++++++++----- .../search_bar_background_rounded_corners_shape.xml | 21 +++++++++++++++++++++ .../impl/toolbar/res/layout/expanded_search_bar.xml | 4 ++-- .../main/impl/toolbar/res/layout/toolbar_layout.xml | 2 -- .../android/dialer/theme/base/res/values/attr.xml | 2 ++ .../theme/base/res/values/theme_dialer_light.xml | 1 + .../hidden/res/values-night/colors_dialer_dark.xml | 1 + .../theme/hidden/res/values/colors_dialer_light.xml | 1 + 8 files changed, 40 insertions(+), 9 deletions(-) create mode 100644 java/com/android/dialer/main/impl/toolbar/res/drawable/search_bar_background_rounded_corners_shape.xml diff --git a/java/com/android/dialer/main/impl/toolbar/res/drawable/search_bar_background_rounded_corners.xml b/java/com/android/dialer/main/impl/toolbar/res/drawable/search_bar_background_rounded_corners.xml index 88f5a04ca..2130db443 100644 --- a/java/com/android/dialer/main/impl/toolbar/res/drawable/search_bar_background_rounded_corners.xml +++ b/java/com/android/dialer/main/impl/toolbar/res/drawable/search_bar_background_rounded_corners.xml @@ -14,8 +14,15 @@ ~ See the License for the specific language governing permissions and ~ limitations under the License --> - - - - + + + + + + + + + + + diff --git a/java/com/android/dialer/main/impl/toolbar/res/drawable/search_bar_background_rounded_corners_shape.xml b/java/com/android/dialer/main/impl/toolbar/res/drawable/search_bar_background_rounded_corners_shape.xml new file mode 100644 index 000000000..ee3219ec1 --- /dev/null +++ b/java/com/android/dialer/main/impl/toolbar/res/drawable/search_bar_background_rounded_corners_shape.xml @@ -0,0 +1,21 @@ + + + + + + diff --git a/java/com/android/dialer/main/impl/toolbar/res/layout/expanded_search_bar.xml b/java/com/android/dialer/main/impl/toolbar/res/layout/expanded_search_bar.xml index a7b3aebd2..d9051a691 100644 --- a/java/com/android/dialer/main/impl/toolbar/res/layout/expanded_search_bar.xml +++ b/java/com/android/dialer/main/impl/toolbar/res/layout/expanded_search_bar.xml @@ -29,7 +29,7 @@ android:background="?attr/selectableItemBackgroundBorderless" android:contentDescription="@string/action_menu_back_from_search" android:src="@drawable/quantum_ic_arrow_back_vd_theme_24" - android:tint="?android:attr/colorPrimary"/> + android:tint="?colorIcon"/> - \ No newline at end of file + diff --git a/java/com/android/dialer/main/impl/toolbar/res/layout/toolbar_layout.xml b/java/com/android/dialer/main/impl/toolbar/res/layout/toolbar_layout.xml index 049cf2ef5..129aac9dd 100644 --- a/java/com/android/dialer/main/impl/toolbar/res/layout/toolbar_layout.xml +++ b/java/com/android/dialer/main/impl/toolbar/res/layout/toolbar_layout.xml @@ -18,7 +18,6 @@ xmlns:app="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" android:layout_height="@dimen/expanded_search_bar_height" - android:background="?android:attr/colorPrimary" app:contentInsetEnd="0dp" app:contentInsetStart="0dp"> + + diff --git a/java/com/android/dialer/theme/base/res/values/theme_dialer_light.xml b/java/com/android/dialer/theme/base/res/values/theme_dialer_light.xml index 1d9ef699e..f0e7e6fad 100644 --- a/java/com/android/dialer/theme/base/res/values/theme_dialer_light.xml +++ b/java/com/android/dialer/theme/base/res/values/theme_dialer_light.xml @@ -46,6 +46,7 @@ @color/dialer_background_color @android:color/white + @color/dialer_search_bar_color @color/dialer_primary_text_color diff --git a/java/com/android/dialer/theme/hidden/res/values-night/colors_dialer_dark.xml b/java/com/android/dialer/theme/hidden/res/values-night/colors_dialer_dark.xml index 74cbb89c5..8d04c7253 100644 --- a/java/com/android/dialer/theme/hidden/res/values-night/colors_dialer_dark.xml +++ b/java/com/android/dialer/theme/hidden/res/values-night/colors_dialer_dark.xml @@ -19,5 +19,6 @@ #335195EA #5195EA #33ffffff + @color/google_grey_900 #2374CE diff --git a/java/com/android/dialer/theme/hidden/res/values/colors_dialer_light.xml b/java/com/android/dialer/theme/hidden/res/values/colors_dialer_light.xml index 4aa0b121c..e4d1e29aa 100644 --- a/java/com/android/dialer/theme/hidden/res/values/colors_dialer_light.xml +++ b/java/com/android/dialer/theme/hidden/res/values/colors_dialer_light.xml @@ -21,5 +21,6 @@ #F50057 #FAFAFA #1f000000 + @color/google_grey_50 #1C3AA9 -- cgit v1.2.3