mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-20 03:08:19 +00:00
Change the widgets header drawable to be a selector with the state_focused property in addition to the state_expanded property. The focused items are drawn with a focus ring with no ripple, while the unfocused items have a ripple. Bug: 365120324 Test: focus traversal through left widget picker pane Flag: EXEMPT bug fix Change-Id: I710cb9e2d727a061e0c19df15526e8c832f6366b
30 lines
1.5 KiB
XML
30 lines
1.5 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!-- Copyright (C) 2023 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_expanded="true" android:state_focused="false">
|
|
<ripple android:color="@color/accent_ripple_color">
|
|
<item android:drawable="@drawable/bg_widgets_header_two_pane_expanded_unfocused" />
|
|
</ripple>
|
|
</item>
|
|
<item android:state_expanded="false" android:state_focused="false">
|
|
<ripple android:color="@color/accent_ripple_color">
|
|
<item android:drawable="@drawable/bg_widgets_header_two_pane_unexpanded_unfocused" />
|
|
</ripple>
|
|
</item>
|
|
<item android:drawable="@drawable/bg_widgets_header_two_pane_expanded_focused" android:state_expanded="true" android:state_focused="true" />
|
|
<item android:drawable="@drawable/bg_widgets_header_two_pane_unexpanded_focused" android:state_expanded="false" android:state_focused="true" />
|
|
</selector>
|