summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
authorSharvil Nanavati <sharvil@google.com>2015-06-23 16:23:06 -0700
committerSharvil Nanavati <sharvil@google.com>2015-06-23 16:23:06 -0700
commite7908c7ff25e96b938271f7595f7da31cd77ae19 (patch)
tree5aa2ad6e437c4da56af57abc6aada4bcfcd7467f /services
parent2c99ea3524bba58f87a9fefad79aa136538b6e0e (diff)
parent64a4858b3231985b341c57551f79fa83a3a0d329 (diff)
downloadframeworks_base-e7908c7ff25e96b938271f7595f7da31cd77ae19.zip
frameworks_base-e7908c7ff25e96b938271f7595f7da31cd77ae19.tar.gz
frameworks_base-e7908c7ff25e96b938271f7595f7da31cd77ae19.tar.bz2
resolved conflicts for merge of 64a4858b to mnc-dev
Change-Id: I9340b816232285853740c03d5e9898fdd019ff0e
Diffstat (limited to 'services')
-rw-r--r--services/core/java/com/android/server/BluetoothManagerService.java16
1 files changed, 16 insertions, 0 deletions
diff --git a/services/core/java/com/android/server/BluetoothManagerService.java b/services/core/java/com/android/server/BluetoothManagerService.java
index b33b10b..25f8872 100644
--- a/services/core/java/com/android/server/BluetoothManagerService.java
+++ b/services/core/java/com/android/server/BluetoothManagerService.java
@@ -19,6 +19,7 @@ package com.android.server;
import android.Manifest;
import android.app.ActivityManager;
import android.bluetooth.BluetoothAdapter;
+import android.bluetooth.BluetoothDevice;
import android.bluetooth.BluetoothProfile;
import android.bluetooth.IBluetooth;
import android.bluetooth.IBluetoothCallback;
@@ -114,6 +115,13 @@ class BluetoothManagerService extends IBluetoothManager.Stub {
private static final int SERVICE_IBLUETOOTH = 1;
private static final int SERVICE_IBLUETOOTHGATT = 2;
+ private static final String[] DEVICE_TYPE_NAMES = new String[] {
+ "???",
+ "BR/EDR",
+ "LE",
+ "DUAL"
+ };
+
private final Context mContext;
private static int mBleAppCount = 0;
@@ -1801,6 +1809,14 @@ class BluetoothManagerService extends IBluetoothManager.Stub {
} else {
ParcelFileDescriptor pfd = null;
try {
+ writer.println("Bonded devices:");
+ for (BluetoothDevice device : mBluetooth.getBondedDevices()) {
+ writer.println(" " + device.getAddress() +
+ " [" + DEVICE_TYPE_NAMES[device.getType()] + "] " +
+ device.getName());
+ }
+ writer.flush();
+
pfd = ParcelFileDescriptor.dup(fd);
mBluetooth.dump(pfd);
} catch (RemoteException re) {