Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b6a6b1e9 authored by Hyunho's avatar Hyunho
Browse files

Add the config to show the pSIM conversion menu and set it to false

Bug: b/314881248
Test: manual done
Change-Id: I258471182cb9092fade50881f52f7299c10c8da2
parent c1c500ae
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -790,4 +790,7 @@

    <!-- Whether to disable location toggle for ChromeOS devices-->
    <bool name="config_disable_location_toggle_for_chrome">false</bool>

    <!-- Whether to display pSIM conversion menu in Settings.-->
    <bool name="config_psim_conversion_menu_enabled">false</bool>
</resources>
+4 −0
Original line number Diff line number Diff line
@@ -42,6 +42,7 @@ import androidx.preference.Preference;
import androidx.preference.PreferenceScreen;

import com.android.internal.telephony.util.TelephonyUtils;
import com.android.settings.R;
import com.android.settings.network.MobileNetworkRepository;
import com.android.settings.network.SubscriptionUtil;
import com.android.settingslib.core.lifecycle.Lifecycle;
@@ -110,6 +111,9 @@ public class ConvertToEsimPreferenceController extends TelephonyBasePreferenceCo
         * To avoid showing users dialogs that can cause confusion,
         * add conditions to allow conversion in the absence of active eSIM.
         */
        if (!mContext.getResources().getBoolean(R.bool.config_psim_conversion_menu_enabled)) {
            return CONDITIONALLY_UNAVAILABLE;
        }
        if (findConversionSupportComponent()) {
            return mSubscriptionInfoEntity != null && mSubscriptionInfoEntity.isActiveSubscriptionId
                    && !mSubscriptionInfoEntity.isEmbedded && isActiveSubscription(subId)