Loading services/core/java/com/android/server/am/ActivityStackSupervisor.java +3 −4 Original line number Diff line number Diff line Loading @@ -3354,11 +3354,10 @@ public final class ActivityStackSupervisor implements DisplayListener { // preserve the old window until the new one is drawn. This prevents having a gap // between the removal and addition, in which no window is visible. We also want the // entrance of the new window to be properly animated. mWindowManager.setReplacingWindow(topActivity.appToken, true /* animate */); mWindowManager.setReplacingWindow(topActivity.appToken); } final ActivityStack stack = moveTaskToStackUncheckedLocked(task, stackId, toTop, forceFocus, "moveTaskToStack:" + reason); final ActivityStack stack = moveTaskToStackUncheckedLocked( task, stackId, toTop, forceFocus, "moveTaskToStack:" + reason); // Make sure the task has the appropriate bounds/size for the stack it is in. if (stackId == FULLSCREEN_WORKSPACE_STACK_ID && task.mBounds != null) { Loading services/core/java/com/android/server/wm/AppWindowToken.java +0 −2 Original line number Diff line number Diff line Loading @@ -128,8 +128,6 @@ class AppWindowToken extends WindowToken { boolean mWillReplaceWindow; // If true, the replaced window was already requested to be removed. boolean mReplacingRemoveRequested; // Whether the replacement of the window should trigger app transition animation. boolean mAnimateReplacingWindow; // If not null, the window that will be used to replace the old one. This is being set when // the window is added and unset when this window reports its first draw. WindowState mReplacingWindow; Loading services/core/java/com/android/server/wm/WindowManagerService.java +10 −6 Original line number Diff line number Diff line Loading @@ -2077,7 +2077,7 @@ public class WindowManagerService extends IWindowManager.Stub } private void prepareWindowReplacementTransition(AppWindowToken atoken) { if (atoken == null || !atoken.mWillReplaceWindow || !atoken.mAnimateReplacingWindow) { if (atoken == null || !atoken.mWillReplaceWindow) { return; } atoken.allDrawn = false; Loading Loading @@ -8556,8 +8556,7 @@ public class WindowManagerService extends IWindowManager.Stub } else if (wtoken != null) { winAnimator.mAnimLayer = w.mLayer + wtoken.mAppAnimator.animLayerAdjustment; if (wtoken.mWillReplaceWindow && wtoken.mAnimateReplacingWindow && wtoken.mReplacingWindow != w) { if (wtoken.mWillReplaceWindow && wtoken.mReplacingWindow != w) { // We know that we will be animating a relaunching window in the near future, // which will receive a z-order increase. We want the replaced window to // immediately receive the same treatment, e.g. to be above the dock divider. Loading Loading @@ -10094,9 +10093,8 @@ public class WindowManagerService extends IWindowManager.Stub * Hint to a token that its activity will relaunch, which will trigger removal and addition of * a window. * @param token Application token for which the activity will be relaunched. * @param animate Whether to animate the addition of the new window. */ public void setReplacingWindow(IBinder token, boolean animate) { public void setReplacingWindow(IBinder token) { synchronized (mWindowMap) { AppWindowToken appWindowToken = findAppWindowToken(token); if (appWindowToken == null) { Loading @@ -10107,7 +10105,13 @@ public class WindowManagerService extends IWindowManager.Stub + " as replacing window."); appWindowToken.mWillReplaceWindow = true; appWindowToken.mHasReplacedWindow = false; appWindowToken.mAnimateReplacingWindow = animate; // Set-up dummy animation so we can start treating windows associated with this token // like they are in transition before the new app window is ready for us to run the // real transition animation. if (DEBUG_APP_TRANSITIONS) Slog.v(TAG, "setReplacingWindow() Setting dummy animation on: " + appWindowToken); appWindowToken.mAppAnimator.setDummyAnimation(); } } Loading services/core/java/com/android/server/wm/WindowState.java +0 −1 Original line number Diff line number Diff line Loading @@ -1388,7 +1388,6 @@ final class WindowState implements WindowManagerPolicy.WindowState { && token.mHasReplacedWindow) { if (DEBUG_ADD_REMOVE) Slog.d(TAG, "Removing replacing window: " + this); token.mWillReplaceWindow = false; token.mAnimateReplacingWindow = false; token.mReplacingRemoveRequested = false; token.mReplacingWindow = null; token.mHasReplacedWindow = false; Loading Loading
services/core/java/com/android/server/am/ActivityStackSupervisor.java +3 −4 Original line number Diff line number Diff line Loading @@ -3354,11 +3354,10 @@ public final class ActivityStackSupervisor implements DisplayListener { // preserve the old window until the new one is drawn. This prevents having a gap // between the removal and addition, in which no window is visible. We also want the // entrance of the new window to be properly animated. mWindowManager.setReplacingWindow(topActivity.appToken, true /* animate */); mWindowManager.setReplacingWindow(topActivity.appToken); } final ActivityStack stack = moveTaskToStackUncheckedLocked(task, stackId, toTop, forceFocus, "moveTaskToStack:" + reason); final ActivityStack stack = moveTaskToStackUncheckedLocked( task, stackId, toTop, forceFocus, "moveTaskToStack:" + reason); // Make sure the task has the appropriate bounds/size for the stack it is in. if (stackId == FULLSCREEN_WORKSPACE_STACK_ID && task.mBounds != null) { Loading
services/core/java/com/android/server/wm/AppWindowToken.java +0 −2 Original line number Diff line number Diff line Loading @@ -128,8 +128,6 @@ class AppWindowToken extends WindowToken { boolean mWillReplaceWindow; // If true, the replaced window was already requested to be removed. boolean mReplacingRemoveRequested; // Whether the replacement of the window should trigger app transition animation. boolean mAnimateReplacingWindow; // If not null, the window that will be used to replace the old one. This is being set when // the window is added and unset when this window reports its first draw. WindowState mReplacingWindow; Loading
services/core/java/com/android/server/wm/WindowManagerService.java +10 −6 Original line number Diff line number Diff line Loading @@ -2077,7 +2077,7 @@ public class WindowManagerService extends IWindowManager.Stub } private void prepareWindowReplacementTransition(AppWindowToken atoken) { if (atoken == null || !atoken.mWillReplaceWindow || !atoken.mAnimateReplacingWindow) { if (atoken == null || !atoken.mWillReplaceWindow) { return; } atoken.allDrawn = false; Loading Loading @@ -8556,8 +8556,7 @@ public class WindowManagerService extends IWindowManager.Stub } else if (wtoken != null) { winAnimator.mAnimLayer = w.mLayer + wtoken.mAppAnimator.animLayerAdjustment; if (wtoken.mWillReplaceWindow && wtoken.mAnimateReplacingWindow && wtoken.mReplacingWindow != w) { if (wtoken.mWillReplaceWindow && wtoken.mReplacingWindow != w) { // We know that we will be animating a relaunching window in the near future, // which will receive a z-order increase. We want the replaced window to // immediately receive the same treatment, e.g. to be above the dock divider. Loading Loading @@ -10094,9 +10093,8 @@ public class WindowManagerService extends IWindowManager.Stub * Hint to a token that its activity will relaunch, which will trigger removal and addition of * a window. * @param token Application token for which the activity will be relaunched. * @param animate Whether to animate the addition of the new window. */ public void setReplacingWindow(IBinder token, boolean animate) { public void setReplacingWindow(IBinder token) { synchronized (mWindowMap) { AppWindowToken appWindowToken = findAppWindowToken(token); if (appWindowToken == null) { Loading @@ -10107,7 +10105,13 @@ public class WindowManagerService extends IWindowManager.Stub + " as replacing window."); appWindowToken.mWillReplaceWindow = true; appWindowToken.mHasReplacedWindow = false; appWindowToken.mAnimateReplacingWindow = animate; // Set-up dummy animation so we can start treating windows associated with this token // like they are in transition before the new app window is ready for us to run the // real transition animation. if (DEBUG_APP_TRANSITIONS) Slog.v(TAG, "setReplacingWindow() Setting dummy animation on: " + appWindowToken); appWindowToken.mAppAnimator.setDummyAnimation(); } } Loading
services/core/java/com/android/server/wm/WindowState.java +0 −1 Original line number Diff line number Diff line Loading @@ -1388,7 +1388,6 @@ final class WindowState implements WindowManagerPolicy.WindowState { && token.mHasReplacedWindow) { if (DEBUG_ADD_REMOVE) Slog.d(TAG, "Removing replacing window: " + this); token.mWillReplaceWindow = false; token.mAnimateReplacingWindow = false; token.mReplacingRemoveRequested = false; token.mReplacingWindow = null; token.mHasReplacedWindow = false; Loading