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

Commit c0008d11 authored by Eric Laurent's avatar Eric Laurent Committed by Android (Google) Code Review
Browse files

Merge "handle in and out audio device connection separately"

parents 0c2cb9bc b71e58b6
Loading
Loading
Loading
Loading
+1 −9
Original line number Diff line number Diff line
@@ -273,15 +273,7 @@ status_t AudioPolicyManager::setDeviceConnectionState(audio_devices_t device,
                            0);
        }

        if (device == AUDIO_DEVICE_OUT_WIRED_HEADSET) {
            device = AUDIO_DEVICE_IN_WIRED_HEADSET;
        } else if (device == AUDIO_DEVICE_OUT_BLUETOOTH_SCO ||
                   device == AUDIO_DEVICE_OUT_BLUETOOTH_SCO_HEADSET ||
                   device == AUDIO_DEVICE_OUT_BLUETOOTH_SCO_CARKIT) {
            device = AUDIO_DEVICE_IN_BLUETOOTH_SCO_HEADSET;
        } else {
        return NO_ERROR;
        }
    }  // end if is output device

    // handle input devices