blob: cf9570b63b28bc6fd38f6e21f3bd94dddd0845d2 [file] [log] [blame]
<?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.
-->
<selector
xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:state_activated="true">
<shape
xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="oval">
<stroke
android:color="@color/car_tint"
android:width="@dimen/car_action_bar_activation_ring_stroke_width">
</stroke>
<size
android:height="@dimen/car_action_bar_activation_ring_radius"
android:width="@dimen/car_action_bar_activation_ring_radius"/>
</shape>
</item>
<!--Yes, this is a load-bearing invisible circle.-->
<!--Android doesn't remeasure foregrounds when state_activated changes, -->
<!--so we need a default drawable with the same size as the one we actually want to draw-->
<item>
<shape
xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="oval">
<stroke
android:color="#00000000"
android:width="@dimen/car_action_bar_activation_ring_stroke_width">
</stroke>
<size
android:height="@dimen/car_action_bar_activation_ring_radius"
android:width="@dimen/car_action_bar_activation_ring_radius"/>
</shape>
</item>
</selector>