Loading core/java/android/provider/Settings.java +0 −7 Original line number Diff line number Diff line Loading @@ -2797,7 +2797,6 @@ public final class Settings { MOVED_TO_GLOBAL.add(Settings.Global.USB_MASS_STORAGE_ENABLED); MOVED_TO_GLOBAL.add(Settings.Global.USE_GOOGLE_MAIL); MOVED_TO_GLOBAL.add(Settings.Global.WEB_AUTOFILL_QUERY_URL); MOVED_TO_GLOBAL.add(Settings.Global.WIFI_COUNTRY_CODE); MOVED_TO_GLOBAL.add(Settings.Global.WIFI_FRAMEWORK_SCAN_INTERVAL_MS); MOVED_TO_GLOBAL.add(Settings.Global.WIFI_FREQUENCY_BAND); MOVED_TO_GLOBAL.add(Settings.Global.WIFI_IDLE_MS); Loading Loading @@ -5207,12 +5206,6 @@ public final class Settings { public static final String WIFI_NETWORKS_AVAILABLE_REPEAT_DELAY = "wifi_networks_available_repeat_delay"; /** * 802.11 country code in ISO 3166 format * @hide */ public static final String WIFI_COUNTRY_CODE = "wifi_country_code"; /** * The interval in milliseconds to issue wake up scans when wifi needs * to connect. This is necessary to connect to an access point when Loading core/res/res/values/config.xml +4 −0 Original line number Diff line number Diff line Loading @@ -352,6 +352,10 @@ <!-- Wifi driver supports batched scan --> <bool translatable="false" name="config_wifi_batched_scan_supported">false</bool> <!-- Default wifi country code. If the device is going to be sold in the US this needs to be US. Uses ISO 3166 country code --> <string translatable="false" name="config_wifi_default_country_code">US</string> <!-- Flag indicating whether the we should enable the automatic brightness in Settings. Software implementation will be used if config_hardware_auto_brightness_available is not set --> <bool name="config_automatic_brightness_available">false</bool> Loading core/res/res/values/symbols.xml +1 −0 Original line number Diff line number Diff line Loading @@ -817,6 +817,7 @@ <java-symbol type="string" name="wifi_tether_configure_ssid_default" /> <java-symbol type="string" name="wifi_watchdog_network_disabled" /> <java-symbol type="string" name="wifi_watchdog_network_disabled_detailed" /> <java-symbol type="string" name="config_wifi_default_country_code" /> <java-symbol type="string" name="imei" /> <java-symbol type="string" name="meid" /> <java-symbol type="string" name="granularity_label_character" /> Loading wifi/java/android/net/wifi/WifiStateMachine.java +2 −12 Original line number Diff line number Diff line Loading @@ -1456,9 +1456,6 @@ public class WifiStateMachine extends StateMachine { public void setCountryCode(String countryCode, boolean persist) { if (persist) { mPersistedCountryCode = countryCode; Settings.Global.putString(mContext.getContentResolver(), Settings.Global.WIFI_COUNTRY_CODE, countryCode); } sendMessage(CMD_SET_COUNTRY_CODE, countryCode); mWifiP2pChannel.sendMessage(WifiP2pService.SET_COUNTRY_CODE, countryCode); Loading Loading @@ -1691,8 +1688,8 @@ public class WifiStateMachine extends StateMachine { * Set the country code from the system setting value, if any. */ private void setCountryCode() { String countryCode = Settings.Global.getString(mContext.getContentResolver(), Settings.Global.WIFI_COUNTRY_CODE); String countryCode = mContext.getResources().getString( R.string.config_wifi_default_country_code); if (countryCode != null && !countryCode.isEmpty()) { setCountryCode(countryCode, false); } else { Loading Loading @@ -2417,13 +2414,6 @@ public class WifiStateMachine extends StateMachine { case CMD_BOOT_COMPLETED: String countryCode = mPersistedCountryCode; if (TextUtils.isEmpty(countryCode) == false) { Settings.Global.putString(mContext.getContentResolver(), Settings.Global.WIFI_COUNTRY_CODE, countryCode); // it may be that the state transition that should send this info // to the driver happened between mPersistedCountryCode getting set // and now, so simply persisting it here would mean we have sent // nothing to the driver. Send the cmd so it might be set now. sendMessageAtFrontOfQueue(CMD_SET_COUNTRY_CODE, countryCode); } break; Loading wifi/java/android/net/wifi/p2p/WifiP2pService.java +0 −6 Original line number Diff line number Diff line Loading @@ -2545,12 +2545,6 @@ public class WifiP2pService extends IWifiP2pManager.Stub { mServiceTransactionId = 0; mServiceDiscReqId = null; String countryCode = Settings.Global.getString(mContext.getContentResolver(), Settings.Global.WIFI_COUNTRY_CODE); if (countryCode != null && !countryCode.isEmpty()) { mP2pStateMachine.sendMessage(SET_COUNTRY_CODE, countryCode); } updatePersistentNetworks(RELOAD); } Loading Loading
core/java/android/provider/Settings.java +0 −7 Original line number Diff line number Diff line Loading @@ -2797,7 +2797,6 @@ public final class Settings { MOVED_TO_GLOBAL.add(Settings.Global.USB_MASS_STORAGE_ENABLED); MOVED_TO_GLOBAL.add(Settings.Global.USE_GOOGLE_MAIL); MOVED_TO_GLOBAL.add(Settings.Global.WEB_AUTOFILL_QUERY_URL); MOVED_TO_GLOBAL.add(Settings.Global.WIFI_COUNTRY_CODE); MOVED_TO_GLOBAL.add(Settings.Global.WIFI_FRAMEWORK_SCAN_INTERVAL_MS); MOVED_TO_GLOBAL.add(Settings.Global.WIFI_FREQUENCY_BAND); MOVED_TO_GLOBAL.add(Settings.Global.WIFI_IDLE_MS); Loading Loading @@ -5207,12 +5206,6 @@ public final class Settings { public static final String WIFI_NETWORKS_AVAILABLE_REPEAT_DELAY = "wifi_networks_available_repeat_delay"; /** * 802.11 country code in ISO 3166 format * @hide */ public static final String WIFI_COUNTRY_CODE = "wifi_country_code"; /** * The interval in milliseconds to issue wake up scans when wifi needs * to connect. This is necessary to connect to an access point when Loading
core/res/res/values/config.xml +4 −0 Original line number Diff line number Diff line Loading @@ -352,6 +352,10 @@ <!-- Wifi driver supports batched scan --> <bool translatable="false" name="config_wifi_batched_scan_supported">false</bool> <!-- Default wifi country code. If the device is going to be sold in the US this needs to be US. Uses ISO 3166 country code --> <string translatable="false" name="config_wifi_default_country_code">US</string> <!-- Flag indicating whether the we should enable the automatic brightness in Settings. Software implementation will be used if config_hardware_auto_brightness_available is not set --> <bool name="config_automatic_brightness_available">false</bool> Loading
core/res/res/values/symbols.xml +1 −0 Original line number Diff line number Diff line Loading @@ -817,6 +817,7 @@ <java-symbol type="string" name="wifi_tether_configure_ssid_default" /> <java-symbol type="string" name="wifi_watchdog_network_disabled" /> <java-symbol type="string" name="wifi_watchdog_network_disabled_detailed" /> <java-symbol type="string" name="config_wifi_default_country_code" /> <java-symbol type="string" name="imei" /> <java-symbol type="string" name="meid" /> <java-symbol type="string" name="granularity_label_character" /> Loading
wifi/java/android/net/wifi/WifiStateMachine.java +2 −12 Original line number Diff line number Diff line Loading @@ -1456,9 +1456,6 @@ public class WifiStateMachine extends StateMachine { public void setCountryCode(String countryCode, boolean persist) { if (persist) { mPersistedCountryCode = countryCode; Settings.Global.putString(mContext.getContentResolver(), Settings.Global.WIFI_COUNTRY_CODE, countryCode); } sendMessage(CMD_SET_COUNTRY_CODE, countryCode); mWifiP2pChannel.sendMessage(WifiP2pService.SET_COUNTRY_CODE, countryCode); Loading Loading @@ -1691,8 +1688,8 @@ public class WifiStateMachine extends StateMachine { * Set the country code from the system setting value, if any. */ private void setCountryCode() { String countryCode = Settings.Global.getString(mContext.getContentResolver(), Settings.Global.WIFI_COUNTRY_CODE); String countryCode = mContext.getResources().getString( R.string.config_wifi_default_country_code); if (countryCode != null && !countryCode.isEmpty()) { setCountryCode(countryCode, false); } else { Loading Loading @@ -2417,13 +2414,6 @@ public class WifiStateMachine extends StateMachine { case CMD_BOOT_COMPLETED: String countryCode = mPersistedCountryCode; if (TextUtils.isEmpty(countryCode) == false) { Settings.Global.putString(mContext.getContentResolver(), Settings.Global.WIFI_COUNTRY_CODE, countryCode); // it may be that the state transition that should send this info // to the driver happened between mPersistedCountryCode getting set // and now, so simply persisting it here would mean we have sent // nothing to the driver. Send the cmd so it might be set now. sendMessageAtFrontOfQueue(CMD_SET_COUNTRY_CODE, countryCode); } break; Loading
wifi/java/android/net/wifi/p2p/WifiP2pService.java +0 −6 Original line number Diff line number Diff line Loading @@ -2545,12 +2545,6 @@ public class WifiP2pService extends IWifiP2pManager.Stub { mServiceTransactionId = 0; mServiceDiscReqId = null; String countryCode = Settings.Global.getString(mContext.getContentResolver(), Settings.Global.WIFI_COUNTRY_CODE); if (countryCode != null && !countryCode.isEmpty()) { mP2pStateMachine.sendMessage(SET_COUNTRY_CODE, countryCode); } updatePersistentNetworks(RELOAD); } Loading