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

Commit 1eccd55a authored by Raff Tsai's avatar Raff Tsai
Browse files

Remove mobile network v1

Fixes: 142920912
Test: rebuild, robolectric
Change-Id: Ib365ba712af62729ca35abbc370aef087ce52a90
parent d7e52888
Loading
Loading
Loading
Loading
+0 −50
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  Copyright (C) 2018 The Android Open Source Project

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

       http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
  -->

<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical">

    <Toolbar
        android:id="@+id/mobile_action_bar"
        style="?android:attr/actionBarStyle"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:navigationContentDescription="@*android:string/action_bar_up_description"
        android:theme="?android:attr/actionBarTheme"/>

    <FrameLayout
        android:id="@+id/main_content"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_weight="1"/>

    <com.google.android.material.bottomnavigation.BottomNavigationView
        android:id="@+id/bottom_nav"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_alignParentBottom="true"
        android:layout_marginEnd="0dp"
        android:layout_marginStart="0dp"
        android:background="?android:attr/windowBackground"
        app:itemIconTint="@color/bottom_navigation_colors"
        app:itemTextColor="@color/bottom_navigation_colors"
        app:menu="@menu/home_bottom_navigation"/>
</LinearLayout>
+0 −169
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2008 The Android Open Source Project

     Licensed under the Apache License, Version 2.0 (the "License");
     you may not use this file except in compliance with the License.
     You may obtain a copy of the License at

          http://www.apache.org/licenses/LICENSE-2.0

     Unless required by applicable law or agreed to in writing, software
     distributed under the License is distributed on an "AS IS" BASIS,
     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     See the License for the specific language governing permissions and
     limitations under the License.
-->
<PreferenceScreen
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:settings="http://schemas.android.com/apk/res-auto"
    android:key="mobile_network_pref_screen"
    settings:initialExpandedChildrenCount="4">

    <Preference
        android:key="cdma_lte_data_service_key"
        android:title="@string/cdma_lte_data_service"
        settings:controller="com.android.settings.network.telephony.DataServiceSetupPreferenceController">
    </Preference>

    <SwitchPreference
        android:key="mobile_data_enable"
        android:title="@string/mobile_data_settings_title"
        android:summary="@string/mobile_data_settings_summary"
        settings:controller="com.android.settings.network.telephony.MobileDataPreferenceController"/>

    <com.android.settingslib.RestrictedSwitchPreference
        android:key="button_roaming_key"
        android:title="@string/roaming"
        android:persistent="false"
        android:summaryOn="@string/roaming_enable"
        android:summaryOff="@string/roaming_disable"
        settings:userRestriction="no_data_roaming"
        settings:controller="com.android.settings.network.telephony.RoamingPreferenceController"/>

    <Preference
        android:key="data_usage_summary"
        android:title="@string/mobile_data_usage_title"
        settings:controller="com.android.settings.network.telephony.DataUsagePreferenceController"/>

    <SwitchPreference
        android:key="enhanced_4g_lte"
        android:title="@string/enhanced_4g_lte_mode_title"
        android:persistent="false"
        android:summary="@string/enhanced_4g_lte_mode_summary"
        settings:keywords="@string/keywords_enhance_4g_lte"
        settings:controller="com.android.settings.network.telephony.Enhanced4gLtePreferenceController"/>

    <SwitchPreference
        android:key="4g_calling"
        android:title="@string/enhanced_4g_lte_mode_title_4g_calling"
        android:persistent="false"
        android:summary="@string/enhanced_4g_lte_mode_summary_4g_calling"
        settings:keywords="@string/keywords_enhance_4g_lte"
        settings:controller="com.android.settings.network.telephony.Enhanced4gCallingPreferenceController"/>

    <SwitchPreference
        android:key="advance_call"
        android:title="@string/enhanced_4g_lte_mode_title_advanced_calling"
        android:persistent="false"
        android:summary="@string/enhanced_4g_lte_mode_summary"
        settings:keywords="@string/keywords_enhance_4g_lte"
        settings:controller="com.android.settings.network.telephony.Enhanced4gAdvancedCallingPreferenceController"/>

    <ListPreference
        android:key="preferred_network_mode_key"
        android:title="@string/preferred_network_mode_title"
        android:summary="@string/preferred_network_mode_summary"
        android:entries="@array/preferred_network_mode_choices"
        android:entryValues="@array/preferred_network_mode_values"
        android:dialogTitle="@string/preferred_network_mode_dialogtitle"
        settings:controller="com.android.settings.network.telephony.PreferredNetworkModePreferenceController"/>

    <ListPreference
        android:key="enabled_networks_key"
        android:title="@string/preferred_network_mode_title"
        android:summary="@string/preferred_network_mode_summary"
        android:entries="@array/enabled_networks_choices"
        android:entryValues="@array/enabled_networks_values"
        android:dialogTitle="@string/preferred_network_mode_dialogtitle"
        settings:controller="com.android.settings.network.telephony.EnabledNetworkModePreferenceController"/>

    <Preference
        android:key="carrier_settings_euicc_key"
        android:title="@string/carrier_settings_euicc"
        settings:controller="com.android.settings.network.telephony.EuiccPreferenceController" />

    <PreferenceCategory
        android:key="calling_category"
        android:title="@string/call_category"
        settings:searchable="false">

        <PreferenceScreen
            android:key="wifi_calling"
            android:title="@string/wifi_calling_settings_title"
            android:summary="@string/wifi_calling_summary"
            settings:controller="com.android.settings.network.telephony.WifiCallingPreferenceController" >
            <intent android:action="android.intent.action.MAIN"
                    android:targetPackage="com.android.settings"
                    android:targetClass="com.android.settings.Settings$WifiCallingSettingsActivity">
                        <extra android:name="show_drawer_menu" android:value="true" />
            </intent>
        </PreferenceScreen>

        <SwitchPreference
            android:key="video_calling_key"
            android:title="@string/video_calling_settings_title"
            android:persistent="true"
            settings:controller="com.android.settings.network.telephony.VideoCallingPreferenceController" />

    </PreferenceCategory>

    <com.android.settings.network.telephony.cdma.CdmaListPreference
        android:key="cdma_system_select_key"
        android:title="@string/cdma_system_select_title"
        android:summary="@string/cdma_system_select_summary"
        android:entries="@array/cdma_system_select_choices"
        android:entryValues="@array/cdma_system_select_values"
        android:dialogTitle="@string/cdma_system_select_dialogtitle"
        settings:controller="com.android.settings.network.telephony.cdma.CdmaSystemSelectPreferenceController"/>

    <com.android.settings.network.telephony.cdma.CdmaListPreference
        android:key="cdma_subscription_key"
        android:title="@string/cdma_subscription_title"
        android:summary="@string/cdma_subscription_summary"
        android:entries="@array/cdma_subscription_choices"
        android:entryValues="@array/cdma_subscription_values"
        android:dialogTitle="@string/cdma_subscription_dialogtitle"
        settings:controller="com.android.settings.network.telephony.cdma.CdmaSubscriptionPreferenceController"/>

    <PreferenceCategory
        android:key="network_operators_category_key"
        android:title="@string/network_operator_category"
        settings:controller="com.android.settings.widget.PreferenceCategoryController">

        <SwitchPreference
            android:key="auto_select_key"
            android:title="@string/select_automatically"
            settings:controller="com.android.settings.network.telephony.gsm.AutoSelectPreferenceController"/>

        <Preference
            android:key="choose_network_key"
            android:title="@string/choose_network_title"
            android:fragment="com.android.phone.NetworkSelectSetting"
            settings:controller="com.android.settings.network.telephony.gsm.OpenNetworkSelectPagePreferenceController"/>
    </PreferenceCategory>

    <!--We want separate APN setting from reset of settings because we want user to change it with caution-->
    <com.android.settingslib.RestrictedPreference
        android:key="telephony_apn_key"
        android:persistent="false"
        android:title="@string/mobile_network_apn_title"
        settings:allowDividerAbove="true"
        settings:controller="com.android.settings.network.telephony.ApnPreferenceController"/>

    <Preference
        android:key="carrier_settings_key"
        android:title="@string/carrier_settings_title"
        settings:controller="com.android.settings.network.telephony.CarrierPreferenceController">
    </Preference>

</PreferenceScreen>
+1 −8
Original line number Diff line number Diff line
@@ -106,7 +106,6 @@ import com.android.internal.util.ArrayUtils;
import com.android.internal.widget.LockPatternUtils;
import com.android.settings.core.FeatureFlags;
import com.android.settings.dashboard.profileselector.ProfileFragmentBridge;
import com.android.settings.development.featureflags.FeatureFlagPersistent;
import com.android.settings.password.ChooseLockSettingsHelper;
import com.android.settingslib.widget.ActionBarShadowController;

@@ -534,14 +533,8 @@ public final class Utils extends com.android.settingslib.Utils {
     * TODO: See bug 16533525.
     */
    public static boolean showSimCardTile(Context context) {
        if (FeatureFlagPersistent.isEnabled(context, FeatureFlags.NETWORK_INTERNET_V2)) {
        return false;
    }
        final TelephonyManager tm =
                (TelephonyManager) context.getSystemService(Context.TELEPHONY_SERVICE);

        return tm.getSimCount() > 1;
    }

    /**
     * Queries for the UserInfo of a user. Returns null if the user doesn't exist (was removed).
+0 −2
Original line number Diff line number Diff line
@@ -23,8 +23,6 @@ public class FeatureFlags {
    public static final String AUDIO_SWITCHER_SETTINGS = "settings_audio_switcher";
    public static final String DYNAMIC_SYSTEM = "settings_dynamic_system";
    public static final String HEARING_AID_SETTINGS = "settings_bluetooth_hearing_aid";
    public static final String MOBILE_NETWORK_V2 = "settings_mobile_network_v2";
    public static final String NETWORK_INTERNET_V2 = "settings_network_and_internet_v2";
    public static final String WIFI_DETAILS_DATAUSAGE_HEADER =
            "settings_wifi_details_datausage_header";
    public static final String PERSONAL_WORK_PROFILE = "settings_work_profile";
+0 −1
Original line number Diff line number Diff line
@@ -35,7 +35,6 @@ public class FeatureFlagPersistent {
    static {
        PERSISTENT_FLAGS = new HashSet<>();
        PERSISTENT_FLAGS.add(FeatureFlags.HEARING_AID_SETTINGS);
        PERSISTENT_FLAGS.add(FeatureFlags.NETWORK_INTERNET_V2);
        PERSISTENT_FLAGS.add(FeatureFlags.DYNAMIC_SYSTEM);
    }

Loading