• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<!--
2  ~ Copyright (C) 2023 The Android Open Source Project
3  ~
4  ~ Licensed under the Apache License, Version 2.0 (the "License");
5  ~ you may not use this file except in compliance with the License.
6  ~ You may obtain a copy of the License at
7  ~
8  ~      http://www.apache.org/licenses/LICENSE-2.0
9  ~
10  ~ Unless required by applicable law or agreed to in writing, software
11  ~ distributed under the License is distributed on an "AS IS" BASIS,
12  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  ~ See the License for the specific language governing permissions and
14  ~ limitations under the License.
15  -->
16<selector xmlns:android="http://schemas.android.com/apk/res/android">
17    <item android:state_selected="true" android:state_focused="true" android:state_pressed="true">
18        <layer-list>
19            <item>
20                <ripple android:color="@color/car_ui_ripple_color">
21                    <item android:drawable="@drawable/nav_bar_button_background_selected" />
22                </ripple>
23            </item>
24            <item>
25                <shape android:shape="rectangle">
26                    <solid android:color="@color/car_ui_rotary_focus_pressed_fill_color"/>
27                    <stroke android:width="@dimen/car_ui_rotary_focus_pressed_stroke_width"
28                            android:color="@color/car_ui_rotary_focus_pressed_stroke_color"/>
29                    <corners android:radius="?hvacFanSpeedBarCornerRadius"/>
30                </shape>
31            </item>
32        </layer-list>
33    </item>
34    <item android:state_selected="true" android:state_focused="true">
35        <layer-list>
36            <item>
37                <ripple android:color="@color/car_ui_ripple_color">
38                    <item android:drawable="@drawable/nav_bar_button_background_selected" />
39                </ripple>
40            </item>
41            <item>
42                <shape android:shape="rectangle">
43                    <solid android:color="@color/car_ui_rotary_focus_fill_color"/>
44                    <stroke android:width="@dimen/car_ui_rotary_focus_stroke_width"
45                            android:color="@color/car_ui_rotary_focus_stroke_color"/>
46                    <corners android:radius="?hvacFanSpeedBarCornerRadius"/>
47                </shape>
48            </item>
49        </layer-list>
50    </item>
51    <item android:state_focused="true" android:state_pressed="true">
52        <layer-list>
53            <item>
54                <ripple android:color="@color/car_ui_ripple_color">
55                    <item android:drawable="@drawable/nav_bar_button_background_unselected" />
56                </ripple>
57            </item>
58            <item>
59                <shape android:shape="oval">
60                    <solid android:color="@color/car_ui_rotary_focus_pressed_fill_color"/>
61                    <stroke android:width="@dimen/car_ui_rotary_focus_pressed_stroke_width"
62                            android:color="@color/car_ui_rotary_focus_pressed_stroke_color"/>
63                </shape>
64            </item>
65        </layer-list>
66    </item>
67    <item android:state_focused="true">
68        <layer-list>
69            <item>
70                <ripple android:color="@color/car_ui_ripple_color">
71                    <item android:drawable="@drawable/nav_bar_button_background_unselected" />
72                </ripple>
73            </item>
74            <item>
75                <shape android:shape="oval">
76                    <solid android:color="@color/car_ui_rotary_focus_fill_color"/>
77                    <stroke android:width="@dimen/car_ui_rotary_focus_stroke_width"
78                            android:color="@color/car_ui_rotary_focus_stroke_color"/>
79                </shape>
80            </item>
81        </layer-list>
82    </item>
83    <item android:state_selected="true">
84        <ripple android:color="@color/car_ui_ripple_color">
85            <item android:drawable="@drawable/nav_bar_button_background_selected" />
86        </ripple>
87    </item>
88</selector>