summaryrefslogtreecommitdiffstats
path: root/packages/SystemUI/src/com/android/systemui/statusbar
diff options
context:
space:
mode:
authorSelim Cinek <cinek@google.com>2015-07-31 16:10:32 -0700
committerSelim Cinek <cinek@google.com>2015-07-31 23:24:55 +0000
commitf92a1fdb77311149189ae17244adc51017b89c1e (patch)
tree95e183904889050343f37c099b3178a41bc839e6 /packages/SystemUI/src/com/android/systemui/statusbar
parent00ab35783c3909c783effbf28da6dda2bf67c1a8 (diff)
downloadframeworks_base-f92a1fdb77311149189ae17244adc51017b89c1e.zip
frameworks_base-f92a1fdb77311149189ae17244adc51017b89c1e.tar.gz
frameworks_base-f92a1fdb77311149189ae17244adc51017b89c1e.tar.bz2
Fixed a bug where notifications shadows were blinking out
Bug: 22567770 Change-Id: I2d335241a287d0c64e659221994f19b7c13eccd3
Diffstat (limited to 'packages/SystemUI/src/com/android/systemui/statusbar')
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/ExpandableView.java6
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/stack/StackScrollAlgorithm.java4
2 files changed, 8 insertions, 2 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableView.java b/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableView.java
index ccec759..71baf57 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableView.java
@@ -374,7 +374,11 @@ public abstract class ExpandableView extends FrameLayout {
}
private void updateClipping() {
- mClipRect.set(0, mClipTopOptimization, getWidth(), getActualHeight());
+ int top = mClipTopOptimization;
+ if (top >= getActualHeight()) {
+ top = getActualHeight() - 1;
+ }
+ mClipRect.set(0, top, getWidth(), getActualHeight());
setClipBounds(mClipRect);
}
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackScrollAlgorithm.java b/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackScrollAlgorithm.java
index 5d2e5b7..82064a7 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackScrollAlgorithm.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackScrollAlgorithm.java
@@ -413,7 +413,9 @@ public class StackScrollAlgorithm {
ExpandableNotificationRow topHeadsUpEntry = ambientState.getTopHeadsUpEntry();
int childCount = algorithmState.visibleChildren.size();
- int numberOfElementsCompletelyIn = (int) algorithmState.itemsInTopStack;
+ int numberOfElementsCompletelyIn = algorithmState.partialInTop == 1.0f
+ ? algorithmState.lastTopStackIndex
+ : (int) algorithmState.itemsInTopStack;
for (int i = 0; i < childCount; i++) {
ExpandableView child = algorithmState.visibleChildren.get(i);
StackViewState childViewState = resultState.getViewStateForView(child);