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

Commit 090e8bd2 authored by Tyler Gunn's avatar Tyler Gunn Committed by Android Git Automerger
Browse files

am e70972cf: Correcting issue where video call icon shows for all calls.

* commit 'e70972cf':
  Correcting issue where video call icon shows for all calls.
parents 5b79ef62 e70972cf
Loading
Loading
Loading
Loading
+14 −6
Original line number Diff line number Diff line
@@ -613,9 +613,23 @@ public class ImsPhoneConnection extends Connection {
        boolean changed = false;

        try {
            // The actual call profile (negotiated between local and peer).
            ImsCallProfile negotiatedCallProfile = imsCall.getCallProfile();
            // The capabilities of the local device.
            ImsCallProfile localCallProfile = imsCall.getLocalCallProfile();
            // The capabilities of the peer device.
            ImsCallProfile remoteCallProfile = imsCall.getRemoteCallProfile();

            if (negotiatedCallProfile != null) {
                int callType = negotiatedCallProfile.mCallType;

                int newVideoState = ImsCallProfile.getVideoStateFromCallType(callType);
                if (getVideoState() != newVideoState) {
                    setVideoState(newVideoState);
                    changed = true;
                }
            }

            if (localCallProfile != null) {
                int callType = localCallProfile.mCallType;

@@ -624,12 +638,6 @@ public class ImsPhoneConnection extends Connection {
                    setLocalVideoCapable(newLocalVideoCapable);
                    changed = true;
                }

                int newVideoState = ImsCallProfile.getVideoStateFromCallType(callType);
                if (getVideoState() != newVideoState) {
                    setVideoState(newVideoState);
                    changed = true;
                }
            }

            int newAudioQuality =