Loading services/core/java/com/android/server/am/ActivityStack.java +4 −1 Original line number Diff line number Diff line Loading @@ -134,7 +134,6 @@ import android.os.Looper; import android.os.Message; import android.os.RemoteException; import android.os.SystemClock; import android.os.Trace; import android.os.UserHandle; import android.service.voice.IVoiceInteractionSession; import android.util.ArraySet; Loading Loading @@ -4789,6 +4788,10 @@ class ActivityStack<T extends StackWindowController> extends ConfigurationContai } } void onPipAnimationEndResize() { mWindowContainerController.onPipAnimationEndResize(); } /** * Adjust bounds to stay within stack bounds. Loading services/core/java/com/android/server/am/ActivityStackSupervisor.java +6 −0 Original line number Diff line number Diff line Loading @@ -2968,6 +2968,12 @@ public class ActivityStackSupervisor extends ConfigurationContainer implements D insetBounds.right = tempPinnedTaskBounds.width(); insetBounds.bottom = tempPinnedTaskBounds.height(); } if (pinnedBounds != null && tempPinnedTaskBounds == null) { // We have finished the animation into PiP, and are resizing the tasks to match the // stack bounds, while layouts are deferred, update any task state as a part of // transitioning it from fullscreen into a floating state. stack.onPipAnimationEndResize(); } stack.resize(pinnedBounds, tempPinnedTaskBounds, insetBounds); stack.ensureVisibleActivitiesConfigurationLocked(r, false); } finally { Loading services/core/java/com/android/server/wm/StackWindowController.java +6 −0 Original line number Diff line number Diff line Loading @@ -192,6 +192,12 @@ public class StackWindowController } } public void onPipAnimationEndResize() { synchronized (mService.mWindowMap) { mContainer.onPipAnimationEndResize(); } } /** * @see TaskStack.getStackDockedModeBoundsLocked(Rect, Rect, Rect, boolean) */ Loading services/core/java/com/android/server/wm/TaskStack.java +12 −10 Original line number Diff line number Diff line Loading @@ -1667,16 +1667,6 @@ public class TaskStack extends WindowContainer<Task> implements @Override // AnimatesBounds public void onAnimationEnd(boolean schedulePipModeChangedCallback, Rect finalStackSize, boolean moveToFullscreen) { // Hold the lock since this is called from the BoundsAnimator running on the UiThread synchronized (mService.mWindowMap) { mBoundsAnimating = false; for (int i = 0; i < mChildren.size(); i++) { final Task t = mChildren.get(i); t.clearPreserveNonFloatingState(); } mService.requestTraversal(); } if (inPinnedWindowingMode()) { // Update to the final bounds if requested. This is done here instead of in the bounds // animator to allow us to coordinate this after we notify the PiP mode changed Loading Loading @@ -1706,6 +1696,18 @@ public class TaskStack extends WindowContainer<Task> implements } } /** * Called immediately prior to resizing the tasks at the end of the pinned stack animation. */ public void onPipAnimationEndResize() { mBoundsAnimating = false; for (int i = 0; i < mChildren.size(); i++) { final Task t = mChildren.get(i); t.clearPreserveNonFloatingState(); } mService.requestTraversal(); } @Override public boolean shouldDeferStartOnMoveToFullscreen() { // Workaround for the recents animation -- normally we need to wait for the new activity to Loading Loading
services/core/java/com/android/server/am/ActivityStack.java +4 −1 Original line number Diff line number Diff line Loading @@ -134,7 +134,6 @@ import android.os.Looper; import android.os.Message; import android.os.RemoteException; import android.os.SystemClock; import android.os.Trace; import android.os.UserHandle; import android.service.voice.IVoiceInteractionSession; import android.util.ArraySet; Loading Loading @@ -4789,6 +4788,10 @@ class ActivityStack<T extends StackWindowController> extends ConfigurationContai } } void onPipAnimationEndResize() { mWindowContainerController.onPipAnimationEndResize(); } /** * Adjust bounds to stay within stack bounds. Loading
services/core/java/com/android/server/am/ActivityStackSupervisor.java +6 −0 Original line number Diff line number Diff line Loading @@ -2968,6 +2968,12 @@ public class ActivityStackSupervisor extends ConfigurationContainer implements D insetBounds.right = tempPinnedTaskBounds.width(); insetBounds.bottom = tempPinnedTaskBounds.height(); } if (pinnedBounds != null && tempPinnedTaskBounds == null) { // We have finished the animation into PiP, and are resizing the tasks to match the // stack bounds, while layouts are deferred, update any task state as a part of // transitioning it from fullscreen into a floating state. stack.onPipAnimationEndResize(); } stack.resize(pinnedBounds, tempPinnedTaskBounds, insetBounds); stack.ensureVisibleActivitiesConfigurationLocked(r, false); } finally { Loading
services/core/java/com/android/server/wm/StackWindowController.java +6 −0 Original line number Diff line number Diff line Loading @@ -192,6 +192,12 @@ public class StackWindowController } } public void onPipAnimationEndResize() { synchronized (mService.mWindowMap) { mContainer.onPipAnimationEndResize(); } } /** * @see TaskStack.getStackDockedModeBoundsLocked(Rect, Rect, Rect, boolean) */ Loading
services/core/java/com/android/server/wm/TaskStack.java +12 −10 Original line number Diff line number Diff line Loading @@ -1667,16 +1667,6 @@ public class TaskStack extends WindowContainer<Task> implements @Override // AnimatesBounds public void onAnimationEnd(boolean schedulePipModeChangedCallback, Rect finalStackSize, boolean moveToFullscreen) { // Hold the lock since this is called from the BoundsAnimator running on the UiThread synchronized (mService.mWindowMap) { mBoundsAnimating = false; for (int i = 0; i < mChildren.size(); i++) { final Task t = mChildren.get(i); t.clearPreserveNonFloatingState(); } mService.requestTraversal(); } if (inPinnedWindowingMode()) { // Update to the final bounds if requested. This is done here instead of in the bounds // animator to allow us to coordinate this after we notify the PiP mode changed Loading Loading @@ -1706,6 +1696,18 @@ public class TaskStack extends WindowContainer<Task> implements } } /** * Called immediately prior to resizing the tasks at the end of the pinned stack animation. */ public void onPipAnimationEndResize() { mBoundsAnimating = false; for (int i = 0; i < mChildren.size(); i++) { final Task t = mChildren.get(i); t.clearPreserveNonFloatingState(); } mService.requestTraversal(); } @Override public boolean shouldDeferStartOnMoveToFullscreen() { // Workaround for the recents animation -- normally we need to wait for the new activity to Loading