Loading services/core/java/com/android/server/wm/AppWindowToken.java +9 −5 Original line number Diff line number Diff line Loading @@ -2503,14 +2503,18 @@ class AppWindowToken extends WindowToken implements WindowManagerService.AppFree @Override public SurfaceControl getAnimationLeashParent() { // All normal app transitions take place in an animation layer which is below the pinned // stack but may be above the parent stacks of the given animating apps. // For transitions in the pinned stack (menu activity) we just let them occur as a child // of the pinned stack. if (!inPinnedWindowingMode()) { return getAppAnimationLayer(); } else { // All normal app transitions take place in an animation layer which is below the pinned // stack but may be above the parent stacks of the given animating apps by default. When // a new hierarchical animation is enabled, we just let them occur as a child of the parent // stack, i.e. the hierarchy of the surfaces is unchanged. if (inPinnedWindowingMode()) { return getStack().getSurfaceControl(); } else if (WindowManagerService.sHierarchicalAnimations) { return super.getAnimationLeashParent(); } else { return getAppAnimationLayer(); } } Loading services/core/java/com/android/server/wm/Task.java +3 −0 Original line number Diff line number Diff line Loading @@ -613,6 +613,9 @@ class Task extends WindowContainer<AppWindowToken> implements ConfigurationConta @Override public SurfaceControl getAnimationLeashParent() { if (!WindowManagerService.sHierarchicalAnimations) { return super.getAnimationLeashParent(); } // Currently, only the recents animation will create animation leashes for tasks. In this // case, reparent the task to the home animation layer while it is being animated to allow // the home activity to reorder the app windows relative to its own. Loading services/core/java/com/android/server/wm/WindowManagerService.java +16 −0 Original line number Diff line number Diff line Loading @@ -375,6 +375,22 @@ public class WindowManagerService extends IWindowManager.Stub // trying to apply a new one. private static final boolean ALWAYS_KEEP_CURRENT = true; /** * If set, new app transition framework which supports setting animation on any element * in a surface is used. * <p> * Only set this to non-zero once the new app transition framework is productionalized. * </p> */ private static final String HIERARCHICAL_ANIMATIONS_PROPERTY = "persist.wm.hierarchical_animations"; /** * @see #HIERARCHICAL_ANIMATIONS_PROPERTY */ static boolean sHierarchicalAnimations = SystemProperties.getBoolean(HIERARCHICAL_ANIMATIONS_PROPERTY, false); // Enums for animation scale update types. @Retention(RetentionPolicy.SOURCE) @IntDef({WINDOW_ANIMATION_SCALE, TRANSITION_ANIMATION_SCALE, ANIMATION_DURATION_SCALE}) Loading Loading
services/core/java/com/android/server/wm/AppWindowToken.java +9 −5 Original line number Diff line number Diff line Loading @@ -2503,14 +2503,18 @@ class AppWindowToken extends WindowToken implements WindowManagerService.AppFree @Override public SurfaceControl getAnimationLeashParent() { // All normal app transitions take place in an animation layer which is below the pinned // stack but may be above the parent stacks of the given animating apps. // For transitions in the pinned stack (menu activity) we just let them occur as a child // of the pinned stack. if (!inPinnedWindowingMode()) { return getAppAnimationLayer(); } else { // All normal app transitions take place in an animation layer which is below the pinned // stack but may be above the parent stacks of the given animating apps by default. When // a new hierarchical animation is enabled, we just let them occur as a child of the parent // stack, i.e. the hierarchy of the surfaces is unchanged. if (inPinnedWindowingMode()) { return getStack().getSurfaceControl(); } else if (WindowManagerService.sHierarchicalAnimations) { return super.getAnimationLeashParent(); } else { return getAppAnimationLayer(); } } Loading
services/core/java/com/android/server/wm/Task.java +3 −0 Original line number Diff line number Diff line Loading @@ -613,6 +613,9 @@ class Task extends WindowContainer<AppWindowToken> implements ConfigurationConta @Override public SurfaceControl getAnimationLeashParent() { if (!WindowManagerService.sHierarchicalAnimations) { return super.getAnimationLeashParent(); } // Currently, only the recents animation will create animation leashes for tasks. In this // case, reparent the task to the home animation layer while it is being animated to allow // the home activity to reorder the app windows relative to its own. Loading
services/core/java/com/android/server/wm/WindowManagerService.java +16 −0 Original line number Diff line number Diff line Loading @@ -375,6 +375,22 @@ public class WindowManagerService extends IWindowManager.Stub // trying to apply a new one. private static final boolean ALWAYS_KEEP_CURRENT = true; /** * If set, new app transition framework which supports setting animation on any element * in a surface is used. * <p> * Only set this to non-zero once the new app transition framework is productionalized. * </p> */ private static final String HIERARCHICAL_ANIMATIONS_PROPERTY = "persist.wm.hierarchical_animations"; /** * @see #HIERARCHICAL_ANIMATIONS_PROPERTY */ static boolean sHierarchicalAnimations = SystemProperties.getBoolean(HIERARCHICAL_ANIMATIONS_PROPERTY, false); // Enums for animation scale update types. @Retention(RetentionPolicy.SOURCE) @IntDef({WINDOW_ANIMATION_SCALE, TRANSITION_ANIMATION_SCALE, ANIMATION_DURATION_SCALE}) Loading