summaryrefslogtreecommitdiff
path: root/service
diff options
context:
space:
mode:
authorTreeHugger Robot <treehugger-gerrit@google.com>2019-10-24 04:42:13 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2019-10-24 04:42:13 +0000
commiteae90dbbe9dd66ecfe4ecb107ec1bc331bab0032 (patch)
treedce991f3491af30ef63d3d3fea63f40d73976b69 /service
parentdce2c33e0eef9dc258ac3ed6484a0a65be78b203 (diff)
parenta6e71aa377080f61b641f4c51ee79bbd2060ac2c (diff)
Merge "Do not clear Wifi country code upon entering airplane mode"
Diffstat (limited to 'service')
-rw-r--r--service/java/com/android/server/wifi/WifiCountryCode.java13
-rw-r--r--service/java/com/android/server/wifi/WifiServiceImpl.java4
2 files changed, 0 insertions, 17 deletions
diff --git a/service/java/com/android/server/wifi/WifiCountryCode.java b/service/java/com/android/server/wifi/WifiCountryCode.java
index 3771cf7a7..1d4edf319 100644
--- a/service/java/com/android/server/wifi/WifiCountryCode.java
+++ b/service/java/com/android/server/wifi/WifiCountryCode.java
@@ -81,7 +81,6 @@ public class WifiCountryCode {
context.registerReceiver(new BroadcastReceiver() {
@Override
public void onReceive(Context context, Intent intent) {
- final String action = intent.getAction();
String countryCode = intent.getStringExtra(TelephonyManager.EXTRA_NETWORK_COUNTRY);
Log.d(TAG, "Country code changed");
setCountryCodeAndUpdate(countryCode);
@@ -102,18 +101,6 @@ public class WifiCountryCode {
}
}
- /**
- * This is called when airplane mode is enabled.
- * In this case we should invalidate all other country code except the
- * phone default one.
- */
- public synchronized void airplaneModeEnabled() {
- Log.d(TAG, "Airplane Mode Enabled");
- // Airplane mode is enabled, we need to reset the country code to phone default.
- // Country code will be set upon when wpa_supplicant starts next time.
- mTelephonyCountryCode = null;
- }
-
private void initializeTelephonyCountryCodeIfNeeded() {
// If we don't have a country code set, read it from telephony on bootup.
if (mTelephonyCountryCode == null) {
diff --git a/service/java/com/android/server/wifi/WifiServiceImpl.java b/service/java/com/android/server/wifi/WifiServiceImpl.java
index fb597005a..3da7a1194 100644
--- a/service/java/com/android/server/wifi/WifiServiceImpl.java
+++ b/service/java/com/android/server/wifi/WifiServiceImpl.java
@@ -322,10 +322,6 @@ public class WifiServiceImpl extends BaseWifiService {
if (mSettingsStore.handleAirplaneModeToggled()) {
mActiveModeWarden.airplaneModeToggled();
}
- if (mSettingsStore.isAirplaneModeOn()) {
- Log.d(TAG, "resetting country code because Airplane mode is ON");
- mCountryCode.airplaneModeEnabled();
- }
}
},
new IntentFilter(Intent.ACTION_AIRPLANE_MODE_CHANGED));