diff options
author | Jackson Fan <xyfan@motorola.com> | 2009-08-19 21:01:29 +0800 |
---|---|---|
committer | Nick Pelly <npelly@google.com> | 2009-08-24 19:02:58 -0700 |
commit | 9abcf0982edcda6d14fd8057fe0cfd2147cac477 (patch) | |
tree | 2ceee68b1978a05864a1790aff19465163eed1a9 /core/java | |
parent | df8a3f31d871db25e952972c2eb346a71186e9e3 (diff) | |
download | frameworks_base-9abcf0982edcda6d14fd8057fe0cfd2147cac477.zip frameworks_base-9abcf0982edcda6d14fd8057fe0cfd2147cac477.tar.gz frameworks_base-9abcf0982edcda6d14fd8057fe0cfd2147cac477.tar.bz2 |
Use correct UUID to authorize AVRCP
Diffstat (limited to 'core/java')
-rw-r--r-- | core/java/android/bluetooth/BluetoothUuid.java | 5 | ||||
-rw-r--r-- | core/java/android/server/BluetoothEventLoop.java | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/core/java/android/bluetooth/BluetoothUuid.java b/core/java/android/bluetooth/BluetoothUuid.java index 1ec7fb3..c15bc20 100644 --- a/core/java/android/bluetooth/BluetoothUuid.java +++ b/core/java/android/bluetooth/BluetoothUuid.java @@ -37,6 +37,7 @@ public final class BluetoothUuid { public static final UUID Handsfree = UUID.fromString("0000111E-0000-1000-8000-00805F9B34FB"); public static final UUID AvrcpController = UUID.fromString("0000110E-0000-1000-8000-00805F9B34FB"); + public static final UUID AvrcpTarget = UUID.fromString("0000110C-0000-1000-8000-00805F9B34FB"); public static boolean isAudioSource(UUID uuid) { return uuid.equals(AudioSource); @@ -61,4 +62,8 @@ public final class BluetoothUuid { public static boolean isAvrcpController(UUID uuid) { return uuid.equals(AvrcpController); } + + public static boolean isAvrcpTarget(UUID uuid) { + return uuid.equals(AvrcpTarget); + } } diff --git a/core/java/android/server/BluetoothEventLoop.java b/core/java/android/server/BluetoothEventLoop.java index 6610d0e..34d6d03 100644 --- a/core/java/android/server/BluetoothEventLoop.java +++ b/core/java/android/server/BluetoothEventLoop.java @@ -431,7 +431,7 @@ class BluetoothEventLoop { boolean authorized = false; UUID uuid = UUID.fromString(deviceUuid); if (mBluetoothService.isEnabled() && - (BluetoothUuid.isAudioSink(uuid) || BluetoothUuid.isAvrcpController(uuid) + (BluetoothUuid.isAudioSink(uuid) || BluetoothUuid.isAvrcpTarget(uuid) || BluetoothUuid.isAdvAudioDist(uuid))) { BluetoothA2dp a2dp = new BluetoothA2dp(mContext); BluetoothDevice device = mAdapter.getRemoteDevice(address); |