From 6ec8855b0a324441340331ce8f407a4f4e80f792 Mon Sep 17 00:00:00 2001 From: Beverly Date: Fri, 11 Feb 2022 16:43:31 +0000 Subject: [PATCH] Delay display DOZE on LS => AOD ScreenOffAnimationController only handles the states from UNLOCKED => AOD, so we weren't delaying the display state change to DOZE when we were animating from LS => AOD. Test: manual Fixes: 219030172 Change-Id: Ia0aff7c634a01855db02d01a194db7850554b77b --- .../android/systemui/statusbar/phone/DozeParameters.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/DozeParameters.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/DozeParameters.java index d610b372702df..b141110a2ec29 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/DozeParameters.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/DozeParameters.java @@ -309,7 +309,12 @@ public class DozeParameters implements * delayed for a few seconds. This might be useful to play animations without reducing FPS. */ public boolean shouldDelayDisplayDozeTransition() { - return mScreenOffAnimationController.shouldDelayDisplayDozeTransition(); + return willAnimateFromLockScreenToAod() + || mScreenOffAnimationController.shouldDelayDisplayDozeTransition(); + } + + private boolean willAnimateFromLockScreenToAod() { + return getAlwaysOn() && mKeyguardShowing; } /**