diff options
author | Jaikumar Ganesh <jaikumar@google.com> | 2010-12-21 22:31:44 -0800 |
---|---|---|
committer | Jaikumar Ganesh <jaikumar@google.com> | 2010-12-22 15:24:18 -0800 |
commit | 15c7439acb22ab079dd2ebe42bdf0d2ffd525c5d (patch) | |
tree | 25fac424972b32834a98a1c0a2ee53ca1970f1a9 /services | |
parent | 93e7d00f3f0466c088f70568941f5276316b9bd2 (diff) | |
download | frameworks_base-15c7439acb22ab079dd2ebe42bdf0d2ffd525c5d.zip frameworks_base-15c7439acb22ab079dd2ebe42bdf0d2ffd525c5d.tar.gz frameworks_base-15c7439acb22ab079dd2ebe42bdf0d2ffd525c5d.tar.bz2 |
Add TYPE_BLUETOOTH network interface for reverse tethering.
Change-Id: I2aa61ce15f57aea9e8fd3a4cb56799c8bc51e998
Diffstat (limited to 'services')
-rw-r--r-- | services/java/com/android/server/ConnectivityService.java | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/services/java/com/android/server/ConnectivityService.java b/services/java/com/android/server/ConnectivityService.java index 3e2eac2..e7e4302 100644 --- a/services/java/com/android/server/ConnectivityService.java +++ b/services/java/com/android/server/ConnectivityService.java @@ -16,8 +16,7 @@ package com.android.server; -import android.app.Notification; -import android.app.NotificationManager; +import android.bluetooth.BluetoothTetheringDataTracker; import android.content.ContentResolver; import android.content.Context; import android.content.Intent; @@ -26,9 +25,9 @@ import android.database.ContentObserver; import android.net.ConnectivityManager; import android.net.DummyDataStateTracker; import android.net.IConnectivityManager; +import android.net.LinkProperties; import android.net.MobileDataStateTracker; import android.net.NetworkInfo; -import android.net.LinkProperties; import android.net.NetworkStateTracker; import android.net.NetworkUtils; import android.net.Proxy; @@ -50,7 +49,6 @@ import android.util.EventLog; import android.util.Slog; import com.android.internal.telephony.Phone; - import com.android.server.connectivity.Tethering; import java.io.FileDescriptor; @@ -58,7 +56,6 @@ import java.io.FileWriter; import java.io.IOException; import java.io.PrintWriter; import java.net.InetAddress; -import java.net.InetSocketAddress; import java.net.UnknownHostException; import java.util.ArrayList; import java.util.Collection; @@ -412,6 +409,10 @@ public class ConnectivityService extends IConnectivityManager.Stub { mNetAttributes[netType].mName); mNetTrackers[netType].startMonitoring(context, mHandler); break; + case ConnectivityManager.TYPE_BLUETOOTH: + mNetTrackers[netType] = BluetoothTetheringDataTracker.getInstance(); + mNetTrackers[netType].startMonitoring(context, mHandler); + break; default: loge("Trying to create a DataStateTracker for an unknown radio type " + mNetAttributes[netType].mRadio); |