[LE Audio] Remove the broadcast icon when the device does not support

broadcast feature

Bug: 254743785
Test: manual test
Test: make RunSettingsRoboTests ROBOTEST_FILTER=MediaOutputIndicatorWorkerTest
Test: make RunSettingsRoboTests ROBOTEST_FILTER=MediaVolumePreferenceControllerTest
Change-Id: I02e429b3a306e2f9b0e2342118649208617c4944
This commit is contained in:
changbetty
2022-10-24 10:29:07 +00:00
parent 062b18c736
commit 4f42ca1eac
4 changed files with 52 additions and 3 deletions

View File

@@ -165,6 +165,13 @@ public class MediaOutputIndicatorWorker extends SliceBackgroundWorker implements
return mPackageName;
}
/** Check if this device supports LE Audio Broadcast feature */
public boolean isBroadcastSupported() {
LocalBluetoothLeBroadcast broadcast =
mLocalBluetoothManager.getProfileManager().getLeAudioBroadcastProfile();
return broadcast != null ? true : false;
}
public boolean isDeviceBroadcasting() {
LocalBluetoothLeBroadcast broadcast =
mLocalBluetoothManager.getProfileManager().getLeAudioBroadcastProfile();