Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2f5b5ea4 authored by Timi Rautamäki's avatar Timi Rautamäki
Browse files

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
parent 9f5f0ee9
Loading
Loading
Loading
Loading
+12 −5
Original line number Diff line number Diff line
@@ -14,8 +14,15 @@
  ~ See the License for the specific language governing permissions and
  ~ limitations under the License
  -->
<shape xmlns:android="http://schemas.android.com/apk/res/android"
  android:shape="rectangle">
  <solid android:color="?android:attr/colorBackgroundFloating"/>
  <corners android:radius="2dp"/>
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
    android:color="@color/dialer_ripple_color">

    <item android:id="@android:id/mask">
        <shape android:shape="rectangle">
            <solid android:color="@android:color/white" />
            <corners android:radius="8dp" />
        </shape>
    </item>

  <item android:drawable="@drawable/search_bar_background_rounded_corners_shape" />
</ripple>
+21 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ Copyright (C) 2018 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
  -->
<shape xmlns:android="http://schemas.android.com/apk/res/android"
  android:shape="rectangle">
  <solid android:color="?attr/colorBackgroundSearchBar"/>
  <corners android:radius="8dp"/>
</shape>
+2 −2
Original line number Diff line number Diff line
@@ -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"/>

  <EditText
      android:id="@+id/search_view"
+0 −2
Original line number Diff line number Diff line
@@ -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">
  <FrameLayout
@@ -38,7 +37,6 @@
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          android:layout_gravity="center_vertical"
          android:background="?android:attr/selectableItemBackground"
          android:gravity="center_vertical">

        <ImageView
+2 −0
Original line number Diff line number Diff line
@@ -15,6 +15,8 @@
  ~ limitations under the License
  -->
<resources>
  <!-- Used to color the search bar background -->
  <attr name="colorBackgroundSearchBar" format="color"/>
  <!-- Used to style all icons in Dialer. -->
  <attr name="colorIcon" format="color"/>
  <!-- Used to style some icons a little lighter in Dialer. -->
Loading