diff options
author | Scott Kennedy <skennedy@google.com> | 2015-02-10 15:52:30 -0800 |
---|---|---|
committer | Scott Kennedy <skennedy@google.com> | 2015-02-10 16:16:10 -0800 |
commit | e5d17d57be3b89a6adb7d429a4cb3cb1fbb422ff (patch) | |
tree | 291cdb12b016211b1b1b6086076302ce3a2d4771 /res | |
parent | 8b7a8ad508d450576b9c71c6a83e4c671fc01aa5 (diff) | |
download | android_frameworks_opt_chips-e5d17d57be3b89a6adb7d429a4cb3cb1fbb422ff.tar.gz android_frameworks_opt_chips-e5d17d57be3b89a6adb7d429a4cb3cb1fbb422ff.tar.bz2 android_frameworks_opt_chips-e5d17d57be3b89a6adb7d429a4cb3cb1fbb422ff.zip |
Highlight the text that matches the constraint
The name and email will now be the same color, and the first instance
of text that matches the query will be highlighted a darker grey.
This code was copied from Inbox.
Change-Id: Ia7857bc31880259db0e7876eb50617f764fc3ceb
Diffstat (limited to 'res')
-rw-r--r-- | res/color/chips_dropdown_text.xml (renamed from res/color/chips_dropdown_subtitle_text.xml) | 6 | ||||
-rw-r--r-- | res/color/chips_dropdown_title_text.xml | 23 | ||||
-rw-r--r-- | res/values/colors.xml | 6 | ||||
-rw-r--r-- | res/values/styles.xml | 4 |
4 files changed, 10 insertions, 29 deletions
diff --git a/res/color/chips_dropdown_subtitle_text.xml b/res/color/chips_dropdown_text.xml index e7b0f3e..7d333bc 100644 --- a/res/color/chips_dropdown_subtitle_text.xml +++ b/res/color/chips_dropdown_text.xml @@ -17,7 +17,7 @@ <selector xmlns:android="http://schemas.android.com/apk/res/android"> - <item android:state_activated="true" android:color="@android:color/white"/> - <item android:color="#757575"/> + <item android:state_activated="true" android:color="@color/chips_dropdown_text_activated"/> + <item android:color="@color/chips_dropdown_text_default"/> -</selector>
\ No newline at end of file +</selector> diff --git a/res/color/chips_dropdown_title_text.xml b/res/color/chips_dropdown_title_text.xml deleted file mode 100644 index 7c79390..0000000 --- a/res/color/chips_dropdown_title_text.xml +++ /dev/null @@ -1,23 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- - Copyright (C) 2014 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. ---> - -<selector xmlns:android="http://schemas.android.com/apk/res/android"> - - <item android:state_activated="true" android:color="@android:color/white"/> - <item android:color="#212121"/> - -</selector>
\ No newline at end of file diff --git a/res/values/colors.xml b/res/values/colors.xml index 5bdfd0f..5130a32 100644 --- a/res/values/colors.xml +++ b/res/values/colors.xml @@ -26,4 +26,8 @@ <color name="chip_background_selected">#4285f4</color> <color name="chip_background_invalid">#db4437</color> -</resources>
\ No newline at end of file + <color name="chips_dropdown_text_default">#212121</color> + <color name="chips_dropdown_text_activated">@android:color/white</color> + <color name="chips_dropdown_text_highlighted">#757575</color> + +</resources> diff --git a/res/values/styles.xml b/res/values/styles.xml index 5c7dcec..8cb48e0 100644 --- a/res/values/styles.xml +++ b/res/values/styles.xml @@ -59,7 +59,7 @@ <item name="android:ellipsize">middle</item> <item name="android:singleLine">true</item> <item name="android:textAlignment">viewStart</item> - <item name="android:textColor">@color/chips_dropdown_title_text</item> + <item name="android:textColor">@color/chips_dropdown_text</item> <item name="android:textSize">16sp</item> </style> @@ -70,7 +70,7 @@ <item name="android:ellipsize">middle</item> <item name="android:singleLine">true</item> <item name="android:textAlignment">viewStart</item> - <item name="android:textColor">@color/chips_dropdown_subtitle_text</item> + <item name="android:textColor">@color/chips_dropdown_text</item> <item name="android:textSize">14sp</item> </style> |