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

Commit 66dafd49 authored by Qing Zhong's avatar Qing Zhong Committed by Android (Google) Code Review
Browse files

Merge "Make call back order right for DISCONNECTED call" into main

parents 1a1b110f 278fdb13
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -2661,7 +2661,9 @@ public final class Call {
        // remove ourselves from the Phone. Note that we do this after completing all state updates
        // so a client can cleanly transition all their UI to the state appropriate for a
        // DISCONNECTED Call while still relying on the existence of that Call in the Phone's list.
        if (mState == STATE_DISCONNECTED) {
        // Check if the original state is already disconnected, otherwise onCallRemoved will be
        // triggered before onCallAdded.
        if (mState == STATE_DISCONNECTED && stateChanged) {
            fireCallDestroyed();
        }
    }
+3 −0
Original line number Diff line number Diff line
@@ -174,6 +174,9 @@ public final class Phone {
            checkCallTree(parcelableCall);
            call.internalUpdate(parcelableCall, mCallByTelecomCallId);
            fireCallAdded(call);
            if (call.getState() == Call.STATE_DISCONNECTED) {
                internalRemoveCall(call);
            }
        } else {
            Log.w(this, "Call %s added, but it was already present", call.internalGetCallId());
            checkCallTree(parcelableCall);