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

Commit ebd26c26 authored by Naomi Musgrave's avatar Naomi Musgrave Committed by Automerger Merge Worker
Browse files

Merge "[MediaProjection] Immediately clean up mirrored surface." into...

Merge "[MediaProjection] Immediately clean up mirrored surface." into sc-v2-dev am: 65b9e723 am: 27e6506b

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

Change-Id: Ia5de4e8c702aa47498b09c1735c0f8ad9ee11f0c
parents 922a3d58 27e6506b
Loading
Loading
Loading
Loading
+7 −0
Original line number Original line Diff line number Diff line
@@ -5747,6 +5747,13 @@ class DisplayContent extends RootDisplayArea implements WindowManagerPolicy.Disp
        }
        }
        mRemoved = true;
        mRemoved = true;


        if (mMirroredSurface != null) {
            // Do not wait for the mirrored surface to be garbage collected, but clean up
            // immediately.
            mWmService.mTransactionFactory.get().remove(mMirroredSurface).apply();
            mMirroredSurface = null;
        }

        // Only update focus/visibility for the last one because there may be many root tasks are
        // Only update focus/visibility for the last one because there may be many root tasks are
        // reparented and the intermediate states are unnecessary.
        // reparented and the intermediate states are unnecessary.
        if (lastReparentedRootTask != null) {
        if (lastReparentedRootTask != null) {