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

Commit c3a808d9 authored by Chavi Weingarten's avatar Chavi Weingarten Committed by Android (Google) Code Review
Browse files

Merge "Merge transactions to parent if layer is going to be removed." into pi-dev

parents 0eb46d80 6728e2f3
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -285,7 +285,14 @@ class WindowContainer<E extends WindowContainer> extends ConfigurationContainer<
        }

        if (mSurfaceControl != null) {
            getPendingTransaction().destroy(mSurfaceControl);
            mPendingTransaction.destroy(mSurfaceControl);

            // Merge to parent transaction to ensure the transactions on this WindowContainer are
            // applied in native even if WindowContainer is removed.
            if (mParent != null) {
                mParent.getPendingTransaction().merge(mPendingTransaction);
            }

            mSurfaceControl = null;
            scheduleAnimation();
        }