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

Commit 7fcfe4d7 authored by Riddle Hsu's avatar Riddle Hsu Committed by Android (Google) Code Review
Browse files

Merge "Set display change ready only if no one sets"

parents 5d6486e6 906c8f0f
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -2022,9 +2022,15 @@ class Transition implements BLASTSyncEngine.TransactionReadyListener {
            final DisplayContent dc = wc.asDisplayContent();
            if (dc == null || !mChanges.get(dc).hasChanged()) continue;
            dc.sendNewConfiguration();
            // Set to ready if no other change controls the ready state. But if there is, such as
            // if an activity is pausing, it will call setReady(ar, false) and wait for the next
            // resumed activity. Then do not set to ready because the transition only contains
            // partial participants. Otherwise the transition may only handle HIDE and miss OPEN.
            if (!mReadyTracker.mUsed) {
                setReady(dc, true);
            }
        }
    }

    boolean getLegacyIsReady() {
        return isCollecting() && mSyncId >= 0;