diff options
| -rw-r--r-- | packages/SystemUI/src/com/android/systemui/statusbar/phone/ScrimState.java | 20 |
1 files changed, 14 insertions, 6 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/ScrimState.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/ScrimState.java index f2a649ba2e32..78d5ae413b4a 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/ScrimState.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/ScrimState.java @@ -46,7 +46,11 @@ public enum ScrimState { mFrontAlpha = 1f; mBehindAlpha = 1f; - mAnimationDuration = ScrimController.ANIMATION_DURATION_LONG; + if (previousState == AOD) { + mAnimateChange = false; + } else { + mAnimationDuration = ScrimController.ANIMATION_DURATION_LONG; + } } @Override @@ -193,11 +197,15 @@ public enum ScrimState { mBehindAlpha = ScrimController.TRANSPARENT; mAnimationDuration = ScrimController.ANIMATION_DURATION_LONG; - // DisplayPowerManager may blank the screen for us, or we might blank it for ourselves - // by animating the screen off via the LightRevelScrim. In either case we just need to - // set our state. - mAnimateChange = mDozeParameters.shouldControlScreenOff() - && !mDozeParameters.shouldShowLightRevealScrim(); + if (previousState == OFF) { + mAnimateChange = false; + } else { + // DisplayPowerManager may blank the screen for us, or we might blank it by + // animating the screen off via the LightRevelScrim. In either case we just need to + // set our state. + mAnimateChange = mDozeParameters.shouldControlScreenOff() + && !mDozeParameters.shouldShowLightRevealScrim(); + } } @Override |