Merge "Merge \\"Don\\'t show the shade background for heads up notifications\\" into nyc-dev am: 6b6bf9cd54 am: f56bcc7925" into nyc-mr1-dev-plus-aosp

This commit is contained in:
Android Build Merger (Role)
2016-06-22 17:11:22 +00:00
committed by Android (Google) Code Review

View File

@@ -152,8 +152,10 @@ public class StackScrollAlgorithm {
float newYTranslation = state.yTranslation;
float newHeight = state.height;
float newNotificationEnd = newYTranslation + newHeight;
if (newYTranslation < previousNotificationEnd) {
boolean isHeadsUp = (child instanceof ExpandableNotificationRow)
&& ((ExpandableNotificationRow) child).isPinned();
if (newYTranslation < previousNotificationEnd && ambientState.isShadeExpanded()
&& !isHeadsUp) {
// The previous view is overlapping on top, clip!
float overlapAmount = previousNotificationEnd - newYTranslation;
state.clipTopAmount = (int) overlapAmount;