From 5a41fe93dada4dd0a6002dc5f9d914029243edfa Mon Sep 17 00:00:00 2001 From: Selim Cinek Date: Wed, 30 Nov 2016 12:18:13 -0800 Subject: [PATCH] Fixed a bug where notifications were stale while collapsing An update to the icons wasn't applied if the shade was currently collapsing. We now ensure that the two states are always in sync. Test: 1) download AndroidBvtTests.apk from data/app from build artefacts 2) adb install -g -r pathToAndroidBvtTests.apk 3) adb shell am instrument -w -e class com.android.androidbvt.SysUINotificationShadeTests#testBundledNotifications com.android.androidbvt/android.support.test.runner.AndroidJUnitRunner Bug: 32437839 Change-Id: I26c097bdda251b4dfddb6dbf0deee74c30560873 --- .../com/android/systemui/statusbar/phone/PhoneStatusBar.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java index bbbdc13d69e34..2a5fc6eabcb01 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java @@ -1873,6 +1873,9 @@ public class PhoneStatusBar extends BaseStatusBar implements DemoMode, updateQsExpansionEnabled(); mShadeUpdates.check(); + + // Let's also update the icons + mIconController.updateNotificationIcons(mNotificationData); } /** @@ -2021,7 +2024,6 @@ public class PhoneStatusBar extends BaseStatusBar implements DemoMode, mNotificationData.filterAndSort(); updateNotificationShade(); - mIconController.updateNotificationIcons(mNotificationData); } public void requestNotificationUpdate() {