Fixed the contrast for low-priority notifications
The low priority notifications had their contrast calculated
against the white background and weren't satisfying
our contrast requirements.
This also aligns the case where the app had no colors better,
and ensures that it's actually using the secondary text
color there.
Test: existing tests pass
Change-Id: Ic11e9d06783e60998f35e0eb7f6f29fb1d86c7df
Fixes: 37444266
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java b/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java
index 8c1b334..9368747 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java
@@ -355,7 +355,8 @@
NotificationColorUtil.getInstance(mContext));
int color = StatusBarIconView.NO_COLOR;
if (colorize) {
- color = mEntry.getContrastedColor(mContext, mIsLowPriority && !isExpanded());
+ color = mEntry.getContrastedColor(mContext, mIsLowPriority && !isExpanded(),
+ getBackgroundColorWithoutTint());
}
expandedIcon.setStaticDrawableColor(color);
}
@@ -859,7 +860,8 @@
private void updateNotificationColor() {
mNotificationColor = NotificationColorUtil.resolveContrastColor(mContext,
- getStatusBarNotification().getNotification().color);
+ getStatusBarNotification().getNotification().color,
+ getBackgroundColorWithoutTint());
}
public HybridNotificationView getSingleLineView() {