diff options
| author | 2015-01-08 04:38:01 +0000 | |
|---|---|---|
| committer | 2015-01-08 04:38:01 +0000 | |
| commit | 1cad8899be13e5eaefbc8300a832a826870ea7ca (patch) | |
| tree | 82cf2be2b99d4a53b616eaf9a1b442a8166e433f | |
| parent | 764a1ba86d3160e4b1e10aa1ac7477539321b42b (diff) | |
| parent | d1646dcfd1d40bdc094f34e05c1359cfc3fa7c65 (diff) | |
Merge "Revert "GpsLocationProvider: Read data enabled status from TelephonyManager."" into lmp-mr1-dev automerge: c010c96
automerge: d1646dc
* commit 'd1646dcfd1d40bdc094f34e05c1359cfc3fa7c65':
Revert "GpsLocationProvider: Read data enabled status from TelephonyManager."
| -rw-r--r-- | services/core/java/com/android/server/location/GpsLocationProvider.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/services/core/java/com/android/server/location/GpsLocationProvider.java b/services/core/java/com/android/server/location/GpsLocationProvider.java index 337e1e311a5e..b46a450bdde7 100644 --- a/services/core/java/com/android/server/location/GpsLocationProvider.java +++ b/services/core/java/com/android/server/location/GpsLocationProvider.java @@ -788,7 +788,9 @@ public class GpsLocationProvider implements LocationProviderInterface { } if (info != null) { - boolean dataEnabled = TelephonyManager.getDefault().getDataEnabled(); + boolean dataEnabled = TelephonyManager.getIntWithSubId(mContext.getContentResolver(), + Settings.Global.MOBILE_DATA, SubscriptionManager.getDefaultSubId(), + 1) == 1; boolean networkAvailable = info.isAvailable() && dataEnabled; String defaultApn = getSelectedApn(); if (defaultApn == null) { |