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

Commit 0d4cbebd authored by Joshua Tsuji's avatar Joshua Tsuji
Browse files

Only notify the floating coordinator of new bounds if we're in PIP.

Fixes: 155389015
Test: manual, set breakpoint and observe onContentMoved is not called on config change if we're not in PIP.
Change-Id: Ic2066ed8c005149be6c568a710d2f0c98fa15f52
parent 9975ac41
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -213,6 +213,10 @@ public class PipTaskOrganizer extends TaskOrganizer {
        return new Rect(mLastReportedBounds);
    }

    public boolean isInPip() {
        return mInPip;
    }

    /**
     * Registers {@link PipTransitionCallback} to receive transition callbacks.
     */
+4 −1
Original line number Diff line number Diff line
@@ -168,8 +168,11 @@ public class PipMotionHelper implements PipAppOpsListener.Callback,
    void synchronizePinnedStackBounds() {
        cancelAnimations();
        mBounds.set(mPipTaskOrganizer.getLastReportedBounds());

        if (mPipTaskOrganizer.isInPip()) {
            mFloatingContentCoordinator.onContentMoved(this);
        }
    }

    /**
     * Synchronizes the current bounds with either the pinned stack, or the ongoing animation. This