Merge "Update UI when BT device is rename" into pi-dev

This commit is contained in:
TreeHugger Robot
2018-05-18 18:06:17 +00:00
committed by Android (Google) Code Review
6 changed files with 18 additions and 10 deletions

View File

@@ -136,7 +136,7 @@ public abstract class AudioSwitchPreferenceController extends BasePreferenceCont
final BluetoothDevice btDevice = mConnectedDevices.get(connectedDeviceIndex);
mSelectedIndex = connectedDeviceIndex;
setActiveBluetoothDevice(btDevice);
listPreference.setSummary(btDevice.getName());
listPreference.setSummary(btDevice.getAliasName());
}
return true;
}
@@ -328,7 +328,7 @@ public abstract class AudioSwitchPreferenceController extends BasePreferenceCont
mediaValues[mSelectedIndex] = mContext.getText(R.string.media_output_default_summary);
for (int i = 0, size = mConnectedDevices.size(); i < size; i++) {
final BluetoothDevice btDevice = mConnectedDevices.get(i);
mediaOutputs[i] = btDevice.getName();
mediaOutputs[i] = btDevice.getAliasName();
mediaValues[i] = btDevice.getAddress();
if (btDevice.equals(activeDevice)) {
// select the active connected device.