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

Commit 2d28bdf1 authored by Tony Huang's avatar Tony Huang Committed by Automerger Merge Worker
Browse files

Merge "Fix black screen while pip to split screen" into sc-dev am: c8b72665

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13982586

Change-Id: Ie4445e21e0ecd928fda0a2efc40ac4934fd81f81
parents 9bd83ee8 c8b72665
Loading
Loading
Loading
Loading
+4 −3
Original line number Diff line number Diff line
@@ -540,9 +540,10 @@ public class PipAnimationController {
                    // WindowContainerTransaction in task organizer
                    final Rect destBounds = getDestinationBounds();
                    getSurfaceTransactionHelper().resetScale(tx, leash, destBounds);
                    if (transitionDirection == TRANSITION_DIRECTION_LEAVE_PIP) {
                        // Leaving to fullscreen, reset crop to null.
                        tx.setPosition(leash, destBounds.left, destBounds.top);
                    if (isOutPipDirection(transitionDirection)) {
                        // Exit pip, clear scale, position and crop.
                        tx.setMatrix(leash, 1, 0, 0, 1);
                        tx.setPosition(leash, 0, 0);
                        tx.setWindowCrop(leash, 0, 0);
                    } else {
                        getSurfaceTransactionHelper().crop(tx, leash, destBounds);
+3 −4
Original line number Diff line number Diff line
@@ -1016,10 +1016,9 @@ public class PipTaskOrganizer implements ShellTaskOrganizer.TaskListener,
            wct.setActivityWindowingMode(mToken, WINDOWING_MODE_UNDEFINED);
            wct.scheduleFinishEnterPip(mToken, destinationBounds);
        } else if (isOutPipDirection(direction)) {
            // If we are animating to fullscreen, then we need to reset the override bounds
            // on the task to ensure that the task "matches" the parent's bounds.
            taskBounds = (direction == TRANSITION_DIRECTION_LEAVE_PIP)
                    ? null : destinationBounds;
            // If we are animating to fullscreen or split screen, then we need to reset the
            // override bounds on the task to ensure that the task "matches" the parent's bounds.
            taskBounds = null;
            applyWindowingModeChangeOnExit(wct, direction);
        } else {
            // Just a resize in PIP