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

Commit 20f7edfc authored by Tyler Gunn's avatar Tyler Gunn Committed by Android (Google) Code Review
Browse files

Merge "API Cleanup: Remove references to VideoState class." into mnc-dev

parents c4f4e7c7 5b882497
Loading
Loading
Loading
Loading
+5 −5
Original line number Diff line number Diff line
@@ -458,15 +458,15 @@ public class Call implements CreateConnectionResponse {
        StringBuilder sb = new StringBuilder();
        sb.append("A");

        if (VideoProfile.VideoState.isTransmissionEnabled(videoState)) {
        if (VideoProfile.isTransmissionEnabled(videoState)) {
            sb.append("T");
        }

        if (VideoProfile.VideoState.isReceptionEnabled(videoState)) {
        if (VideoProfile.isReceptionEnabled(videoState)) {
            sb.append("R");
        }

        if (VideoProfile.VideoState.isPaused(videoState)) {
        if (VideoProfile.isPaused(videoState)) {
            sb.append("P");
        }

@@ -1481,7 +1481,7 @@ public class Call implements CreateConnectionResponse {

    /**
     * The current video state for the call.
     * Valid values: see {@link VideoProfile.VideoState}.
     * See {@link VideoProfile} for a list of valid video states.
     */
    public int getVideoState() {
        return mVideoState;
@@ -1500,7 +1500,7 @@ public class Call implements CreateConnectionResponse {
    /**
     * Determines the current video state for the call.
     * For an outgoing call determines the desired video state for the call.
     * Valid values: see {@link VideoProfile.VideoState}
     * Valid values: see {@link VideoProfile}
     *
     * @param videoState The video state for the call.
     */
+2 −2
Original line number Diff line number Diff line
@@ -185,8 +185,8 @@ public class CallIntentProcessor {
            CallsManager callsManager,
            Intent intent) {
        int intentVideoState = intent.getIntExtra(TelecomManager.EXTRA_START_CALL_WITH_VIDEO_STATE,
                VideoProfile.VideoState.AUDIO_ONLY);
        if (intentVideoState == VideoProfile.VideoState.AUDIO_ONLY
                VideoProfile.STATE_AUDIO_ONLY);
        if (intentVideoState == VideoProfile.STATE_AUDIO_ONLY
                || !callsManager.hasVideoCall()) {
            return false;
        } else {
+1 −3
Original line number Diff line number Diff line
@@ -18,7 +18,6 @@ package com.android.server.telecom;

import android.content.Context;
import android.content.Intent;
import android.Manifest.permission;
import android.net.Uri;
import android.os.AsyncTask;
import android.provider.CallLog.Calls;
@@ -29,7 +28,6 @@ import android.telephony.PhoneNumberUtils;

// TODO: Needed for move to system service: import com.android.internal.R;
import com.android.internal.telephony.CallerInfo;
import com.android.internal.telephony.PhoneConstants;

/**
 * Helper class that provides functionality to write information about calls and their associated
@@ -207,7 +205,7 @@ final class CallLogManager extends CallsManagerListenerBase {
     * @return The call features.
     */
    private static int getCallFeatures(int videoState) {
        if (VideoProfile.VideoState.isVideo(videoState)) {
        if (VideoProfile.isVideo(videoState)) {
            return Calls.FEATURES_VIDEO;
        }
        return 0;
+2 −3
Original line number Diff line number Diff line
@@ -24,7 +24,6 @@ import android.os.Looper;
import android.os.SystemProperties;
import android.os.Trace;
import android.provider.CallLog.Calls;
import android.telecom.AudioState;
import android.telecom.CallAudioState;
import android.telecom.Conference;
import android.telecom.Connection;
@@ -400,7 +399,7 @@ public class CallsManager extends Call.ListenerBase {

    boolean hasVideoCall() {
        for (Call call : mCalls) {
            if (call.getVideoState() != VideoProfile.VideoState.AUDIO_ONLY) {
            if (call.getVideoState() != VideoProfile.STATE_AUDIO_ONLY) {
                return true;
            }
        }
@@ -708,7 +707,7 @@ public class CallsManager extends Call.ListenerBase {
            // We do not update the UI until we get confirmation of the answer() through
            // {@link #markCallAsActive}.
            call.answer(videoState);
            if (VideoProfile.VideoState.isVideo(videoState) &&
            if (VideoProfile.isVideo(videoState) &&
                !mWiredHeadsetManager.isPluggedIn() &&
                !mCallAudioManager.isBluetoothDeviceAvailable() &&
                isSpeakerEnabledForVideoCalls()) {
+1 −2
Original line number Diff line number Diff line
@@ -32,7 +32,6 @@ import android.telecom.DisconnectCause;
import android.telecom.GatewayInfo;
import android.telecom.ParcelableConference;
import android.telecom.ParcelableConnection;
import android.telecom.PhoneAccount;
import android.telecom.PhoneAccountHandle;
import android.telecom.StatusHints;
import android.telecom.TelecomManager;
@@ -763,7 +762,7 @@ final class ConnectionServiceWrapper extends ServiceBinder {
        if (callId != null && isServiceValid("answer")) {
            try {
                logOutgoing("answer %s %d", callId, videoState);
                if (videoState == VideoProfile.VideoState.AUDIO_ONLY) {
                if (videoState == VideoProfile.STATE_AUDIO_ONLY) {
                    mServiceInterface.answer(callId);
                } else {
                    mServiceInterface.answerVideo(callId, videoState);
Loading