diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java b/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java index 9ef495de0b468..d444ea811b3da 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java @@ -903,12 +903,18 @@ public class ExpandableNotificationRow extends ActivatableNotificationView { return mShowingPublic ? mPublicLayout : mPrivateLayout; } + @Override + public void setShowingLegacyBackground(boolean showing) { + super.setShowingLegacyBackground(showing); + mPrivateLayout.setShowingLegacyBackground(showing); + mPublicLayout.setShowingLegacyBackground(showing); + } + public void setExpansionLogger(ExpansionLogger logger, String key) { mLogger = logger; mLoggingKey = key; } - private void logExpansionEvent(boolean userAction, boolean wasExpanded) { final boolean nowExpanded = isExpanded(); if (wasExpanded != nowExpanded && mLogger != null) { diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationContentView.java b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationContentView.java index dec2fc75501b7..8172a4d36ab6a 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationContentView.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationContentView.java @@ -67,6 +67,8 @@ public class NotificationContentView extends FrameLayout { private final Paint mFadePaint = new Paint(); private boolean mAnimate; private boolean mIsHeadsUp; + private boolean mShowingLegacyBackground; + private final ViewTreeObserver.OnPreDrawListener mEnableAnimationPredrawListener = new ViewTreeObserver.OnPreDrawListener() { @Override @@ -421,7 +423,7 @@ public class NotificationContentView extends FrameLayout { public void setDark(boolean dark, boolean fade, long delay) { if (mDark == dark || mContractedChild == null) return; mDark = dark; - mContractedWrapper.setDark(dark, fade, delay); + mContractedWrapper.setDark(dark && !mShowingLegacyBackground, fade, delay); } public void setHeadsUp(boolean headsUp) { @@ -436,4 +438,8 @@ public class NotificationContentView extends FrameLayout { // layout, and saves us some layers. return false; } + + public void setShowingLegacyBackground(boolean showing) { + mShowingLegacyBackground = showing; + } }