From 3d299959deb33a86ba2925eb4fa954e0118bd893 Mon Sep 17 00:00:00 2001 From: Shaoxu Liu Date: Thu, 8 Oct 2015 15:15:27 +0800 Subject: Customize regulatory info. Since the AndroidManifest could not use the overlay boolean, enable the regulatory info in AndroidManifest. Add flag checking to make sure it could be customized to enable or disable. Change-Id: I95018d94dea271eed9d740b356ad883c0b537e28 --- src/com/android/settings/DeviceInfoSettings.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/com/android') diff --git a/src/com/android/settings/DeviceInfoSettings.java b/src/com/android/settings/DeviceInfoSettings.java index 1f0cad1..3a0e061 100644 --- a/src/com/android/settings/DeviceInfoSettings.java +++ b/src/com/android/settings/DeviceInfoSettings.java @@ -180,9 +180,10 @@ public class DeviceInfoSettings extends SettingsPreferenceFragment implements In removePreferenceIfBoolFalse(KEY_UPDATE_SETTING, R.bool.config_additional_system_update_setting_enable); - // Remove regulatory information if none present. + // Remove regulatory information if none present or config_show_regulatory_info is disabled final Intent intent = new Intent(Settings.ACTION_SHOW_REGULATORY_INFO); - if (getPackageManager().queryIntentActivities(intent, 0).isEmpty()) { + if (getPackageManager().queryIntentActivities(intent, 0).isEmpty() + || !getResources().getBoolean(R.bool.config_show_regulatory_info)) { Preference pref = findPreference(KEY_REGULATORY_INFO); if (pref != null) { getPreferenceScreen().removePreference(pref); -- cgit v1.1