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

Commit ce3a9494 authored by Evan Rosky's avatar Evan Rosky
Browse files

Don't meet tf condition if not added due to legacy sync

Apparently TF doesn't use a transition if there is a legacy
sync ongoing, so we also shouldn't track it in the transition.

Bug: 438510757
Test: existing tests + crash report
Flag: EXEMPT bugfix
Change-Id: Ib127425d3f5f1fa531cf265e763f73ae30a2cb0c
parent e1697ea9
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -569,7 +569,8 @@ class WindowOrganizerController extends IWindowOrganizerController.Stub
                // TODO(b/232042367) Redesign the organizer update on activity callback so that we
                // we will know about the transition explicitly.
                final ActionChain chain = mService.mChainTracker.startTransit("tfTransact");
                if (chain.getTransition() == null) {
                final boolean legacySync = chain.getTransition() == null;
                if (legacySync) {
                    // This should rarely happen, and we should try to avoid using
                    // {@link #applySyncTransaction} with Shell transition.
                    // We still want to apply and merge the transaction to the active sync
@@ -582,7 +583,9 @@ class WindowOrganizerController extends IWindowOrganizerController.Stub
                    chain.getTransition().mReadyTracker.add(wctApplied);
                }
                applyTransaction(wct, -1 /* syncId */, chain, caller);
                if (!legacySync) {
                    wctApplied.meet();
                }
                mService.mChainTracker.end();
                return;
            }