diff options
| author | 2024-03-20 10:29:10 -0700 | |
|---|---|---|
| committer | 2024-03-20 10:29:10 -0700 | |
| commit | 3ffdef62e3ce7189cc3aaf53ad045dbee1fb851c (patch) | |
| tree | f725655942fbc344a967f113763cf1a0428c8c8d | |
| parent | feaaf00a34c267ac4c36be8192a193fa41556a55 (diff) | |
Use theme colors for bubble bar drop target
Using colorPrimaryContainer for the background.
Bug: 313661121
Test: manual, change theme and observe the drop target color is updated
Change-Id: I9929b49d1e9750551cf552800265601cd8f9ac4d
| -rw-r--r-- | libs/WindowManager/Shell/res/color/bubble_drop_target_background_color.xml | 20 | ||||
| -rw-r--r-- | libs/WindowManager/Shell/res/drawable/bubble_drop_target_background.xml | 14 |
2 files changed, 28 insertions, 6 deletions
diff --git a/libs/WindowManager/Shell/res/color/bubble_drop_target_background_color.xml b/libs/WindowManager/Shell/res/color/bubble_drop_target_background_color.xml new file mode 100644 index 000000000000..ab1ab984fd5f --- /dev/null +++ b/libs/WindowManager/Shell/res/color/bubble_drop_target_background_color.xml @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="utf-8"?><!-- + ~ Copyright (C) 2024 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" + xmlns:androidprv="http://schemas.android.com/apk/prv/res/android"> + <item android:alpha="0.35" android:color="?androidprv:attr/materialColorPrimaryContainer" /> +</selector>
\ No newline at end of file diff --git a/libs/WindowManager/Shell/res/drawable/bubble_drop_target_background.xml b/libs/WindowManager/Shell/res/drawable/bubble_drop_target_background.xml index 468b5c2a712f..9dcde3b54421 100644 --- a/libs/WindowManager/Shell/res/drawable/bubble_drop_target_background.xml +++ b/libs/WindowManager/Shell/res/drawable/bubble_drop_target_background.xml @@ -1,5 +1,4 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- +<?xml version="1.0" encoding="utf-8"?><!-- ~ Copyright (C) 2024 The Android Open Source Project ~ ~ Licensed under the Apache License, Version 2.0 (the "License"); @@ -14,9 +13,12 @@ ~ See the License for the specific language governing permissions and ~ limitations under the License. --> -<shape android:shape="rectangle" - xmlns:android="http://schemas.android.com/apk/res/android"> - <solid android:color="#bf309fb5" /> +<shape xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:androidprv="http://schemas.android.com/apk/prv/res/android" + android:shape="rectangle"> <corners android:radius="@dimen/bubble_bar_expanded_view_corner_radius" /> - <stroke android:width="1dp" android:color="#A00080FF"/> + <solid android:color="@color/bubble_drop_target_background_color" /> + <stroke + android:width="1dp" + android:color="?androidprv:attr/materialColorPrimaryContainer" /> </shape> |