Revert "Revert "Pass in active device to all BluetoothA2dp APIs ..."
Revert submission 10303287-revert-10253996-bt-a2dp-no-null-FQRXACWPIA Reason for revert: Fixing breakage Reverted Changes: I4d9f2f819:Revert "Make sure calls to BluetoothA2dp APIs pass... I771ca0d57:Revert "Need to now pass in active device instead ... I76529c7a1:Revert "Pass in active device to all BluetoothA2dp... I297bda68d:Revert "Require user pass in a non-null BluetoothD... I525327959:Revert "Pass in active device to all BluetoothA2dp... I1d8660b11:Revert "Pass in active device to all BluetoothA2dp... Bug: 147287141 Test: robotests Change-Id: I5aecfa4b5a8e371b914573ddd080acb98078bfca
This commit is contained in:
@@ -83,9 +83,9 @@ public class BluetoothCodecDialogPreferenceController extends
|
||||
return index;
|
||||
}
|
||||
// Check HD audio is enabled, display the available list.
|
||||
if (bluetoothA2dp.getOptionalCodecsEnabled(activeDevice)
|
||||
if (bluetoothA2dp.isOptionalCodecsEnabled(activeDevice)
|
||||
== BluetoothA2dp.OPTIONAL_CODECS_PREF_ENABLED) {
|
||||
BluetoothCodecConfig[] configs = getSelectableConfigs(null);
|
||||
BluetoothCodecConfig[] configs = getSelectableConfigs(activeDevice);
|
||||
if (configs != null) {
|
||||
return getIndexFromConfig(configs);
|
||||
}
|
||||
@@ -101,7 +101,8 @@ public class BluetoothCodecDialogPreferenceController extends
|
||||
int codecPriorityValue = BluetoothCodecConfig.CODEC_PRIORITY_DEFAULT;
|
||||
switch (index) {
|
||||
case 0:
|
||||
codecTypeValue = getHighestCodec(getSelectableConfigs(null));
|
||||
codecTypeValue = getHighestCodec(getSelectableConfigs(
|
||||
mBluetoothA2dp.getActiveDevice()));
|
||||
codecPriorityValue = BluetoothCodecConfig.CODEC_PRIORITY_HIGHEST;
|
||||
break;
|
||||
case 1:
|
||||
|
||||
Reference in New Issue
Block a user