[Settings][Back port] configuration for hidding SIM provider UI
Hide SIM provider UI based on configuraion. Bug: 240515161 Test: test cases and local testing Change-Id: Ie618485ba5c5fd0223f5c8ba279b3ed418c67e11
This commit is contained in:
@@ -342,7 +342,18 @@ public class NetworkProviderSettings extends RestrictedSettingsFragment
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Whether to show any UI which is SIM related.
|
||||
*/
|
||||
@VisibleForTesting
|
||||
boolean showAnySubscriptionInfo(Context context) {
|
||||
return (context != null) && SubscriptionUtil.isSimHardwareVisible(context);
|
||||
}
|
||||
|
||||
private void addNetworkMobileProviderController() {
|
||||
if (!showAnySubscriptionInfo(getContext())) {
|
||||
return;
|
||||
}
|
||||
if (mNetworkMobileProviderController == null) {
|
||||
mNetworkMobileProviderController = new NetworkMobileProviderController(
|
||||
getContext(), PREF_KEY_PROVIDER_MOBILE_NETWORK);
|
||||
|
||||
Reference in New Issue
Block a user