Developer option crashed when Bluetooth feature disabled
When Bluetooth feature is disabled, crash observed with developer option is selected Bug: 352864331 Change-Id: If4239f710847f2e01a3b419e1ce6f783f0522219
This commit is contained in:
committed by
chaneswar yemme
parent
9a492ca3cb
commit
ec6e93f3f4
@@ -45,10 +45,11 @@ public class BluetoothMaxConnectedAudioDevicesPreferenceController extends
|
|||||||
super(context);
|
super(context);
|
||||||
|
|
||||||
final BluetoothManager bluetoothManager = context.getSystemService(BluetoothManager.class);
|
final BluetoothManager bluetoothManager = context.getSystemService(BluetoothManager.class);
|
||||||
|
if(bluetoothManager != null && bluetoothManager.getAdapter() != null) {
|
||||||
mDefaultMaxConnectedAudioDevices =
|
mDefaultMaxConnectedAudioDevices =
|
||||||
bluetoothManager.getAdapter().getMaxConnectedAudioDevices();
|
bluetoothManager.getAdapter().getMaxConnectedAudioDevices();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String getPreferenceKey() {
|
public String getPreferenceKey() {
|
||||||
|
|||||||
Reference in New Issue
Block a user