Merge "Add the connection state change handle for the volume control profile" into udc-dev am: 2a37e27cf3

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/23276876

Change-Id: I7dd43a48243a2f1217fa9522f636adceac327c74
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
TreeHugger Robot
2023-05-17 06:04:32 +00:00
committed by Automerger Merge Worker

View File

@@ -37,6 +37,7 @@ import android.bluetooth.BluetoothPbapClient;
import android.bluetooth.BluetoothProfile; import android.bluetooth.BluetoothProfile;
import android.bluetooth.BluetoothSap; import android.bluetooth.BluetoothSap;
import android.bluetooth.BluetoothUuid; import android.bluetooth.BluetoothUuid;
import android.bluetooth.BluetoothVolumeControl;
import android.content.Context; import android.content.Context;
import android.content.Intent; import android.content.Intent;
import android.os.ParcelUuid; import android.os.ParcelUuid;
@@ -240,8 +241,8 @@ public class LocalBluetoothProfileManager {
Log.d(TAG, "Adding local Volume Control profile"); Log.d(TAG, "Adding local Volume Control profile");
} }
mVolumeControlProfile = new VolumeControlProfile(mContext, mDeviceManager, this); mVolumeControlProfile = new VolumeControlProfile(mContext, mDeviceManager, this);
// Note: no event handler for VCP, only for being connectable. addProfile(mVolumeControlProfile, VolumeControlProfile.NAME,
mProfileNameMap.put(VolumeControlProfile.NAME, mVolumeControlProfile); BluetoothVolumeControl.ACTION_CONNECTION_STATE_CHANGED);
} }
if (mLeAudioProfile == null && supportedList.contains(BluetoothProfile.LE_AUDIO)) { if (mLeAudioProfile == null && supportedList.contains(BluetoothProfile.LE_AUDIO)) {
if (DEBUG) { if (DEBUG) {