Merge \"PBAP: Allow wearable handsfree device for PBAP Access\" into nyc-mr1-dev

am: 7f44cdd34e

Change-Id: I59c9d97c69c7652e9292beeec20f265bf7a6a41e
This commit is contained in:
Hemant Gupta
2016-06-30 00:04:29 +00:00
committed by android-build-merger

View File

@@ -809,7 +809,9 @@ public final class CachedBluetoothDevice implements Comparable<CachedBluetoothDe
// No separate prompt is displayed after pairing.
if (getPhonebookPermissionChoice() == CachedBluetoothDevice.ACCESS_UNKNOWN) {
if (mDevice.getBluetoothClass().getDeviceClass()
== BluetoothClass.Device.AUDIO_VIDEO_HANDSFREE) {
== BluetoothClass.Device.AUDIO_VIDEO_HANDSFREE ||
mDevice.getBluetoothClass().getDeviceClass()
== BluetoothClass.Device.AUDIO_VIDEO_WEARABLE_HEADSET) {
setPhonebookPermissionChoice(CachedBluetoothDevice.ACCESS_ALLOWED);
} else {
setPhonebookPermissionChoice(CachedBluetoothDevice.ACCESS_REJECTED);