From 606f4d5d8c5e1b3db00d0544cd64dff1dd0581b6 Mon Sep 17 00:00:00 2001 From: Robert Carr Date: Thu, 30 Jun 2016 14:36:27 -0700 Subject: [PATCH] Disable seamless rotation while animating. Neither the animation code or the seamless rotation code is equipped to handle it. Bug: 28838855 Change-Id: Id3739bbc4335936cf3647af4ff97dd4efc134b65 --- .../java/com/android/server/policy/PhoneWindowManager.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/services/core/java/com/android/server/policy/PhoneWindowManager.java b/services/core/java/com/android/server/policy/PhoneWindowManager.java index 0e732271403bc..b1b90d126068c 100644 --- a/services/core/java/com/android/server/policy/PhoneWindowManager.java +++ b/services/core/java/com/android/server/policy/PhoneWindowManager.java @@ -7685,7 +7685,12 @@ public class PhoneWindowManager implements WindowManagerPolicy { return false; } + // We only enable seamless rotation if the top window has requested + // it and is in the fullscreen opaque state. Seamless rotation + // requires freezing various Surface states and won't work well + // with animations, so we disable it in the animation case for now. if (mTopFullscreenOpaqueWindowState != null && mTopIsFullscreen && + !mTopFullscreenOpaqueWindowState.isAnimatingLw() && mTopFullscreenOpaqueWindowState.getAttrs().rotationAnimation == ROTATION_ANIMATION_JUMPCUT) { return true;