Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9bd523da authored by Winson Chung's avatar Winson Chung
Browse files

Explicitly reset the task bounds when removing PIP

- Otherwise the task bounds are reset by WM, but the activity config is
  not updated until it's next started again resulting in a weird
  animation

Change-Id: I6e5aadd3481b7a5c1929d068c78c3ed1a7f6494b
Bug: 157749854
Test: atest PinnedStackTests
parent ef5ab039
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -327,6 +327,11 @@ public class PipTaskOrganizer extends TaskOrganizer implements
        }
        getUpdateHandler().post(() -> {
            try {
                // Reset the task bounds first to ensure the activity configuration is reset as well
                final WindowContainerTransaction wct = new WindowContainerTransaction();
                wct.setBounds(mToken, null);
                WindowOrganizer.applyTransaction(wct);

                ActivityTaskManager.getService().removeStacksInWindowingModes(
                        new int[]{ WINDOWING_MODE_PINNED });
            } catch (RemoteException e) {