Loading res/values/arrays.xml +4 −0 Original line number Diff line number Diff line Loading @@ -1368,4 +1368,8 @@ <item>1</item> <item>2</item> </string-array> <string-array name="hidesupl_plmn_list"> <item>46001</item> </string-array> </resources> res/values/bools.xml +3 −0 Original line number Diff line number Diff line Loading @@ -26,6 +26,9 @@ <!-- Display additional System Update menu if true --> <bool name="config_additional_system_update_setting_enable">false</bool> <!-- Whether to hide SUPL apn for China Union --> <bool name="config_hidesupl_enable">false</bool> <!-- Whether the bluetooth activation confirmation dialogs should be auto dismissed. Can be overridden for specific product builds. --> <bool name="auto_confirm_bluetooth_activation_dialog">false</bool> Loading src/com/android/settings/ApnSettings.java +15 −0 Original line number Diff line number Diff line Loading @@ -264,6 +264,21 @@ public class ApnSettings extends SettingsPreferenceFragment implements //remove the filtered items, no need to show in UI where += " and type <>\"" + APN_TYPE_FOTA + "\""; if (getResources().getBoolean(R.bool.config_hidesupl_enable)) { boolean needHideSupl = false; for (String plmn : getResources().getStringArray(R.array.hidesupl_plmn_list)) { if (plmn.equals(TelephonyManager.getDefault() .getSimOperator(mSubId))) { needHideSupl = true; break; } } if (needHideSupl) { where += " and type <>\"" + PhoneConstants.APN_TYPE_SUPL + "\""; } } //Hide mms if config is true if(getResources().getBoolean(R.bool.config_mms_enable)) { where += " and type <>\"" + APN_TYPE_MMS + "\"" ; Loading Loading
res/values/arrays.xml +4 −0 Original line number Diff line number Diff line Loading @@ -1368,4 +1368,8 @@ <item>1</item> <item>2</item> </string-array> <string-array name="hidesupl_plmn_list"> <item>46001</item> </string-array> </resources>
res/values/bools.xml +3 −0 Original line number Diff line number Diff line Loading @@ -26,6 +26,9 @@ <!-- Display additional System Update menu if true --> <bool name="config_additional_system_update_setting_enable">false</bool> <!-- Whether to hide SUPL apn for China Union --> <bool name="config_hidesupl_enable">false</bool> <!-- Whether the bluetooth activation confirmation dialogs should be auto dismissed. Can be overridden for specific product builds. --> <bool name="auto_confirm_bluetooth_activation_dialog">false</bool> Loading
src/com/android/settings/ApnSettings.java +15 −0 Original line number Diff line number Diff line Loading @@ -264,6 +264,21 @@ public class ApnSettings extends SettingsPreferenceFragment implements //remove the filtered items, no need to show in UI where += " and type <>\"" + APN_TYPE_FOTA + "\""; if (getResources().getBoolean(R.bool.config_hidesupl_enable)) { boolean needHideSupl = false; for (String plmn : getResources().getStringArray(R.array.hidesupl_plmn_list)) { if (plmn.equals(TelephonyManager.getDefault() .getSimOperator(mSubId))) { needHideSupl = true; break; } } if (needHideSupl) { where += " and type <>\"" + PhoneConstants.APN_TYPE_SUPL + "\""; } } //Hide mms if config is true if(getResources().getBoolean(R.bool.config_mms_enable)) { where += " and type <>\"" + APN_TYPE_MMS + "\"" ; Loading