diff --git a/core/java/android/view/RemoteAnimationTarget.java b/core/java/android/view/RemoteAnimationTarget.java index 046232a8afafe..2dac81c66d2a6 100644 --- a/core/java/android/view/RemoteAnimationTarget.java +++ b/core/java/android/view/RemoteAnimationTarget.java @@ -129,7 +129,11 @@ public class RemoteAnimationTarget implements Parcelable { * The index of the element in the tree in prefix order. This should be used for z-layering * to preserve original z-layer order in the hierarchy tree assuming no "boosting" needs to * happen. + * @deprecated WindowManager may set a z-order different from the prefix order, and has set the + * correct layer for the animation leash already, so this should not be used for + * layer any more. */ + @Deprecated @UnsupportedAppUsage public final int prefixOrderIndex; diff --git a/packages/SystemUI/animation/src/com/android/systemui/animation/ActivityLaunchAnimator.kt b/packages/SystemUI/animation/src/com/android/systemui/animation/ActivityLaunchAnimator.kt index 7020603383591..fb80f1c131ade 100644 --- a/packages/SystemUI/animation/src/com/android/systemui/animation/ActivityLaunchAnimator.kt +++ b/packages/SystemUI/animation/src/com/android/systemui/animation/ActivityLaunchAnimator.kt @@ -436,7 +436,6 @@ class ActivityLaunchAnimator(private val launchAnimator: LaunchAnimator) { .withAlpha(1f) .withMatrix(matrix) .withWindowCrop(windowCrop) - .withLayer(window.prefixOrderIndex) .withCornerRadius(cornerRadius) .withVisibility(true) .build()