Reapply "Fix perf regression VisualStabilityCoordinator"
This reverts commit e639f542. Previously revering CL[1] to fix CL[2] made simpleSmartReplyWithLifetimeExtension_matchesScreenshot as presubmit because the CL[1] breaks the notification post by visibility statbility coordiator received mLockscreenInGoneTransition during unlocking to pending the notification pipeline but never reset it. The issue only reproducible when Scene container & keyguard WM refactor flags (flexi) enabled, and the root cause is in SceneContainerStartable didn't invoke statusBarKeyguardViewManager.hide() -> setKeyguardFadingAway(true) when the keyguard transiting to gone in the first place, caused hide() end up being consumed after the keyguard visiblity changed & makes setKeyguardFadingAway(true) invoked after keyguard unlocked without reset it. Moving forward, for flexi will no longer rely on KeyguardStateController callback, as a result, we use SceneContainer#isEnabled as a check to use KeyguardStateController legacy callback for non-flexi to fix this perf regression as a short-term and keep monitoring keyguard gone trancition by alwaysCollectFlow for flexi enabled (and file b/381779933 for tracking potential perf regression for flexi) With that, we can safely repplay the previous reverts CL back. [1]: I14eadece21d48442581d75a7edbb2b383832003d [2]: I71bb0969113dd12ec5ea0f04c79e016b672795bd Flag: com.android.systemui.check_lockscreen_gone_transition Bug: 375302455 Bug: 373203637 Bug: 373169481 Test: atest SystemUIMicrobenchmark Test: atest VisualStabilityCoordinatorTest Test: atest NotificationRemoteInput (with enabling Scene container & keyguard WM refactor flags) Change-Id: Ibbcf21845cb0a87e91117cecc25bc87fa785607c
Loading
Please register or sign in to comment