From 1360a44ded85929dd17f5a14c9e86b8091052635 Mon Sep 17 00:00:00 2001 From: Michal Brzezinski Date: Tue, 25 May 2021 17:28:14 +0100 Subject: [PATCH] Improving performance of notification panel This might not directly fix b/187139139 but it's definitely step in a good direction and we shouldn't check Resources every time when calculating clock position. Bug: 187139139 Test: Performance tests run on demand before: https://android-build.googleplex.com/builds/abtd/run/L97900000900103160 after: https://android-build.googleplex.com/builds/abtd/run/L52500000900103665 Change-Id: I9ef13f957a31232287dcdb9c9848fa8431409377 --- .../statusbar/phone/NotificationPanelViewController.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelViewController.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelViewController.java index 9d8a9bfafe49c..dcdca5c0d122b 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelViewController.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelViewController.java @@ -27,7 +27,6 @@ import static com.android.systemui.classifier.Classifier.QS_COLLAPSE; import static com.android.systemui.classifier.Classifier.QUICK_SETTINGS; import static com.android.systemui.statusbar.StatusBarState.KEYGUARD; import static com.android.systemui.statusbar.notification.stack.NotificationStackScrollLayout.ROWS_ALL; -import static com.android.systemui.util.Utils.shouldUseSplitNotificationShade; import static java.lang.Float.isNaN; @@ -1235,7 +1234,7 @@ public class NotificationPanelViewController extends PanelViewController { bypassEnabled, getUnlockedStackScrollerPadding(), computeQsExpansionFraction(), mDisplayCutoutTopInset, - shouldUseSplitNotificationShade(mFeatureFlags, mResources)); + mShouldUseSplitNotificationShade); mClockPositionAlgorithm.run(mClockPositionResult); boolean animate = mNotificationStackScrollLayoutController.isAddOrRemoveAnimationPending(); boolean animateClock = animate || mAnimateNextPositionUpdate;