From 0c12b4d0d7f8520fd9a3fde7c9bbcd785eab34de Mon Sep 17 00:00:00 2001 From: Matt Pietal Date: Thu, 15 Oct 2020 08:41:51 -0400 Subject: [PATCH] Global Actions - Fix shutdown ui text color The text color is based upon the wallpaper, which is not relevant when using a basic scrim. Have the text color match the global actions menu items and controls. Fixes: 170791176 Test: manual, restart the device Change-Id: I5ff07acbb1a247a6dc8c76ff2be5dc893ae3da96 --- packages/SystemUI/res/values/colors.xml | 2 ++ .../systemui/globalactions/GlobalActionsImpl.java | 10 ++++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/packages/SystemUI/res/values/colors.xml b/packages/SystemUI/res/values/colors.xml index 3d7b779c8a460..6df8b4e733bb1 100644 --- a/packages/SystemUI/res/values/colors.xml +++ b/packages/SystemUI/res/values/colors.xml @@ -54,6 +54,8 @@ @color/GM2_red_400 @color/GM2_grey_100 + @color/control_primary_text + #ff686868 diff --git a/packages/SystemUI/src/com/android/systemui/globalactions/GlobalActionsImpl.java b/packages/SystemUI/src/com/android/systemui/globalactions/GlobalActionsImpl.java index b55b29a804108..a330be6449e23 100644 --- a/packages/SystemUI/src/com/android/systemui/globalactions/GlobalActionsImpl.java +++ b/packages/SystemUI/src/com/android/systemui/globalactions/GlobalActionsImpl.java @@ -140,8 +140,14 @@ public class GlobalActionsImpl implements GlobalActions, CommandQueue.Callbacks d.setContentView(R.layout.shutdown_dialog); d.setCancelable(false); - int color = Utils.getColorAttrDefaultColor(mContext, - com.android.systemui.R.attr.wallpaperTextColor); + int color; + if (mBlurUtils.supportsBlursOnWindows()) { + color = Utils.getColorAttrDefaultColor(mContext, + com.android.systemui.R.attr.wallpaperTextColor); + } else { + color = mContext.getResources().getColor( + com.android.systemui.R.color.global_actions_shutdown_ui_text); + } ProgressBar bar = d.findViewById(R.id.progress); bar.getIndeterminateDrawable().setTint(color);