OSDN Git Service

Let there be color
authorLucas Dupin <dupin@google.com>
Fri, 19 Apr 2019 22:38:42 +0000 (15:38 -0700)
committerLucas Dupin <dupin@google.com>
Fri, 19 Apr 2019 22:38:42 +0000 (15:38 -0700)
Use notification colors even on night mode (enforcing contrast of
course)

Test: pull down shade on LS and launcher
Fixes: 130756560
Change-Id: I3f3f6e426163e316906692ef8b9c416ca94242ee

core/java/com/android/internal/util/ContrastColorUtil.java

index d037d4b..bf088e0 100644 (file)
@@ -455,7 +455,7 @@ public class ContrastColorUtil {
      * Resolves {@param color} to an actual color if it is {@link Notification#COLOR_DEFAULT}
      */
     public static int resolveColor(Context context, int color, boolean defaultBackgroundIsDark) {
-        if (color == Notification.COLOR_DEFAULT || defaultBackgroundIsDark) {
+        if (color == Notification.COLOR_DEFAULT) {
             int res = defaultBackgroundIsDark
                     ? com.android.internal.R.color.notification_default_color_dark
                     : com.android.internal.R.color.notification_default_color_light;