aboutsummaryrefslogtreecommitdiff
path: root/framework/java/android/bluetooth/BluetoothDevice.java
diff options
context:
space:
mode:
authorNick Pelly <npelly@google.com>2009-10-08 00:12:45 +0200
committerNick Pelly <npelly@google.com>2009-10-08 00:27:17 +0200
commit79b3ff80ff00f3186f8d8cc07520a3c211e489a0 (patch)
treecc189b553d084a6717f944c376166e319caab7f1 /framework/java/android/bluetooth/BluetoothDevice.java
parent07b84cb5bb5283352a27cc0cf651586ed00035a0 (diff)
Introduce BluetoothAdapter.getDefaultAdapter().
This is the main entry point to the Bluetooth APIs, and returns the default local Bluetooth adapter. It replaces context.getSystemService(Context.BLUETOOTH_SERVICE). This was never in a public SDK release. DrNo: eastham Bug: 2158765 Joke: Why can't you play cards in the jungle? Because there's too many cheetas! Change-Id: Ieed8be009ee5aba621cb69090ee8c8a9c19c840d
Diffstat (limited to 'framework/java/android/bluetooth/BluetoothDevice.java')
-rw-r--r--framework/java/android/bluetooth/BluetoothDevice.java3
1 files changed, 1 insertions, 2 deletions
diff --git a/framework/java/android/bluetooth/BluetoothDevice.java b/framework/java/android/bluetooth/BluetoothDevice.java
index ce975c2279..9c23746494 100644
--- a/framework/java/android/bluetooth/BluetoothDevice.java
+++ b/framework/java/android/bluetooth/BluetoothDevice.java
@@ -18,7 +18,6 @@ package android.bluetooth;
import android.annotation.SdkConstant;
import android.annotation.SdkConstant.SdkConstantType;
-import android.content.Context;
import android.os.IBinder;
import android.os.Parcel;
import android.os.Parcelable;
@@ -328,7 +327,7 @@ public final class BluetoothDevice implements Parcelable {
/*package*/ static IBluetooth getService() {
synchronized (BluetoothDevice.class) {
if (sService == null) {
- IBinder b = ServiceManager.getService(Context.BLUETOOTH_SERVICE);
+ IBinder b = ServiceManager.getService(BluetoothAdapter.BLUETOOTH_SERVICE);
if (b == null) {
throw new RuntimeException("Bluetooth service not available");
}