summaryrefslogtreecommitdiffstats
path: root/packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
diff options
context:
space:
mode:
authorSelim Cinek <cinek@google.com>2015-08-31 16:15:49 -0700
committerThe Android Automerger <android-build@google.com>2015-09-02 14:05:03 -0700
commit77ed3fc43fdcb45abb861361e12a2444f0cc6d40 (patch)
tree24e38cdcb5a2df8b082e625b0e21c350ba54540d /packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
parentfebca852ed57f50aba8a72bd79862b680dcee6b5 (diff)
downloadframeworks_base-77ed3fc43fdcb45abb861361e12a2444f0cc6d40.zip
frameworks_base-77ed3fc43fdcb45abb861361e12a2444f0cc6d40.tar.gz
frameworks_base-77ed3fc43fdcb45abb861361e12a2444f0cc6d40.tar.bz2
Fixed when the notification effects are being cleared
Previously the notification effects were not correctly cleared in certain cases and the user could end up in a state where the notification light would always blink. Bug: 22931139 Change-Id: I9a71e56cf4479354a9d773b5b6f0edd7693f2b05
Diffstat (limited to 'packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java')
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java10
1 files changed, 6 insertions, 4 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java b/packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
index 7065343..79174c9 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
@@ -1632,11 +1632,13 @@ public abstract class BaseStatusBar extends SystemUI implements
protected void handleVisibleToUserChanged(boolean visibleToUser) {
try {
if (visibleToUser) {
- boolean clearNotificationEffects = !isPanelFullyCollapsed() &&
- (mShowLockscreenNotifications ||
- (mState == StatusBarState.SHADE || mState == StatusBarState.SHADE_LOCKED));
+ boolean pinnedHeadsUp = mHeadsUpManager.hasPinnedHeadsUp();
+ boolean clearNotificationEffects =
+ ((mShowLockscreenNotifications && mState == StatusBarState.KEYGUARD) ||
+ (!pinnedHeadsUp && (mState == StatusBarState.SHADE
+ || mState == StatusBarState.SHADE_LOCKED)));
int notificationLoad = mNotificationData.getActiveNotifications().size();
- if (mHeadsUpManager.hasPinnedHeadsUp() && isPanelFullyCollapsed()) {
+ if (pinnedHeadsUp && isPanelFullyCollapsed()) {
notificationLoad = 1;
} else {
MetricsLogger.histogram(mContext, "note_load", notificationLoad);