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

Commit 043f45f1 authored by Automerger Merge Worker's avatar Automerger Merge Worker
Browse files

Merge "Rollback telephony resources" am: 83cadde6

Change-Id: I60497cddcb6af792d96ee8b9949bb6969f7181ff
parents 5256d9ad 83cadde6
Loading
Loading
Loading
Loading
+0 −21
Original line number Diff line number Diff line
@@ -41,25 +41,6 @@ filegroup {
    srcs: ["jarjar-rules-shared.txt"],
}

android_app {
    name: "telephony-resources",
    installable: true,

    resource_dirs: [
        "res",
    ],

    platform_apis: true,
    manifest: "AndroidManifest_Resources.xml",
    export_package_resources: true,

    product_variables: {
        pdk: {
            // enable this build only when platform library is available
            enabled: false,
        },
    },
}

java_library {
    name: "telephony-common",
@@ -88,9 +69,7 @@ java_library {
        "voip-common",
        "ims-common",
        "unsupportedappusage",
        "telephony-resources",
    ],
    required: ["telephony-resources"],
    static_libs: [
        "android.hardware.radio.config-V1.0-java-shallow",
        "android.hardware.radio.config-V1.1-java-shallow",

res/values/config.xml

deleted100644 → 0
+0 −298
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
/*
** Copyright 2020, 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.
*/
-->

<!-- These resources are around just to allow their values to be customized
     for different hardware and product builds.  Do not translate.

     NOTE: The naming convention is "config_camelCaseValue". Some legacy
     entries do not follow the convention, but all new entries should. -->

<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
    <!-- The RadioAccessFamilies supported by the device.
         Empty is viewed as "all".  Only used on devices which
         don't support RIL_REQUEST_GET_RADIO_CAPABILITY
         format is UMTS|LTE|... -->
    <string translatable="false" name="config_radio_access_family"></string>

    <!-- MMS user agent string -->
    <string name="config_mms_user_agent" translatable="false"></string>

    <!-- MMS user agent prolfile url -->
    <string name="config_mms_user_agent_profile_url" translatable="false"></string>

    <!-- Config determines whether to update phone object when voice registration
         state changes. Voice radio tech change will always trigger an update of
         phone object irrespective of this config -->
    <bool name="config_switch_phone_on_voice_reg_state_change">true</bool>

    <!-- Boolean indicating if restoring network selection should be skipped -->
    <!-- The restoring is handled by modem if it is true-->
    <bool translatable="false" name="skip_restoring_network_selection">false</bool>

    <!-- An array of CDMA roaming indicators which means international roaming -->
    <integer-array translatable="false" name="config_cdma_international_roaming_indicators" />

    <!-- Configure mobile network MTU. The standard default is set here but each carrier
         may have a specific value set in an overlay config.xml file. -->
    <integer name="config_mobile_mtu">1500</integer>

    <!-- Configure mobile tcp buffer sizes in the form:
         rat-name:rmem_min,rmem_def,rmem_max,wmem_min,wmem_def,wmem_max
         If no value is found for the rat-name in use, the system default will be applied.
    -->
    <string-array name="config_mobile_tcp_buffers">
    </string-array>

    <!-- flag to indicate if EF LI/EF PL should be used for system language -->
    <bool name="config_use_sim_language_file">false</bool>

    <!-- List of countries in which we display 'No service' on status bar
         instead of 'Emergency calls only' when SIM is unready. -->
    <string-array translatable="false" name="config_display_no_service_when_sim_unready">
        <item>"DE"</item>
        <item>"GB"</item>
        <item>"JP"</item>
    </string-array>

    <!-- Flag indicating whether the surface flinger is inefficient
         at performing a blur.  Used by parts of the UI to turn off
         the blur effect where it isn't worth the performance hit.
         As of Honeycomb, blurring is not supported anymore. -->
    <bool name="config_sf_slowBlur">true</bool>

    <!-- set to false if we need to show user confirmation
         when alpha identifier is not provided by the UICC -->
    <bool name="config_stkNoAlphaUsrCnf">true</bool>

    <!-- Number of physical SIM slots on the device. This includes both eSIM and pSIM slots, and
         is not necessarily the same as the number of phones/logical modems supported by the device.
         For example, a multi-sim device can have 2 phones/logical modems, but 3 physical slots,
         or a single SIM device can have 1 phones/logical modems, but 2 physical slots (one eSIM
         and one pSIM) -->
    <integer name="config_num_physical_slots">1</integer>

    <!-- Is the device capable of hot swapping an UICC Card -->
    <bool name="config_hotswapCapable">false</bool>

    <!-- An array of device capabilities defined by GSMA SGP.22 v2.0.
         The first item is the capability name that the device supports. The second item is the
         major version. The minor and revision versions are default to 0s.
         The device capabilities and their definition in the spec are:
             gsm : gsmSupportedRelease
             utran : utranSupportedRelease
             cdma1x : cdma2000onexSupportedRelease
             hrpd : cdma2000hrpdSupportedRelease
             ehrpd : cdma2000ehrpdSupportedRelease
             eutran : eutranSupportedRelease
             nfc : contactlessSupportedRelease
             crl : rspCrlSupportedVersion
    -->
    <string-array translatable="false" name="config_telephonyEuiccDeviceCapabilities">
        <!-- Example:
        <item>"gsm,11"</item>
        <item>"utran,11"</item>
        <item>"cdma1x,1"</item>
        <item>"hrpd,3"</item>
        <item>"ehrpd,12"</item>
        <item>"eutran,11"</item>
        <item>"nfc,1"</item>
        <item>"crl,1"</item>
        -->
    </string-array>

    <!-- If this value is true, duplicate Source/Destination port fields
         in WDP header of some carriers OMADM wap push are supported.
         ex: MSGTYPE-TotalSegments-CurrentSegment
             -SourcePortDestPort-SourcePortDestPort-OMADM PDU
         If false, not supported. -->
    <bool name="config_duplicate_port_omadm_wappush">false</bool>

    <!-- Cellular network service package name to bind to by default. -->
    <string name="config_wwan_network_service_package" translatable="false">com.android.phone</string>

    <!-- Cellular network service class name to bind to by default.-->
    <string name="config_wwan_network_service_class" translatable="false"></string>

    <!-- IWLAN network service package name to bind to by default. If none is specified in an overlay, an
         empty string is passed in -->
    <string name="config_wlan_network_service_package" translatable="false"></string>

    <!-- IWLAN network service class name to bind to by default. If none is specified in an overlay, an
         empty string is passed in -->
    <string name="config_wlan_network_service_class" translatable="false"></string>

    <!-- Telephony qualified networks service package name to bind to by default. -->
    <string name="config_qualified_networks_service_package" translatable="false"></string>

    <!-- Telephony qualified networks service class name to bind to by default. -->
    <string name="config_qualified_networks_service_class" translatable="false"></string>

    <!-- Cellular data service package name to bind to by default. If none is specified in an overlay, an
         empty string is passed in -->
    <string name="config_wwan_data_service_package" translatable="false">com.android.phone</string>

    <!-- IWLAN data service package name to bind to by default. If none is specified in an overlay, an
         empty string is passed in -->
    <string name="config_wlan_data_service_package" translatable="false"></string>

    <!-- Cellular data service class name to bind to by default. If none is specified in an overlay, an
         empty string is passed in -->
    <string name="config_wwan_data_service_class" translatable="false"></string>

    <!-- IWLAN data service class name to bind to by default. If none is specified in an overlay, an
         empty string is passed in -->
    <string name="config_wlan_data_service_class" translatable="false"></string>

    <!-- Boolean indicating if RADIO POWER OFF is required on receiving SIM REFRESH with RESET.
         This will be handled by modem if it is false. -->
    <bool name="config_requireRadioPowerOffOnSimRefreshReset">false</bool>

    <!-- Flag specifying whether the device will use the "allow_hold_in_ims_call" carrier config
         option.  When false, the device will support holding of IMS calls, regardless of the
         carrier config setting. -->
    <bool name="config_device_respects_hold_carrier_config">true</bool>

    <!-- Whether to use voip audio mode for ims call -->
    <bool name="config_use_voip_mode_for_ims">false</bool>

    <!-- Enables built-in SIP phone capability -->
    <bool name="config_built_in_sip_phone">true</bool>

    <!-- Flag indicating apps will skip sending hold request before merge. In this case
        IMS service implementation will do both.i.e.hold followed by merge. -->
    <bool name="skipHoldBeforeMerge">true</bool>

    <!-- Flag specifying whether VoLTE is available on device -->
    <bool name="config_device_volte_available">false</bool>

    <!-- Flag specifying whether VT is available on device -->
    <bool name="config_device_vt_available">false</bool>

    <!-- Flag specifying whether WFC over IMS is available on device -->
    <bool name="config_device_wfc_ims_available">false</bool>

    <!-- Flag specifying whether or not IMS will use the dynamic ImsResolver -->
    <bool name="config_dynamic_bind_ims">false</bool>

    <!-- ImsService package name to bind to by default. If none is specified in an overlay, an
         empty string is passed in -->
    <string name="config_ims_package"/>

    <!-- Whether cbrs is supported on the device or not -->
    <bool name="config_cbrs_supported" translatable="false">false</bool>

    <!-- Enables SIP on WIFI only -->
    <bool name="config_sip_wifi_only">false</bool>

    <!-- Name of the dialog that is used to install the carrier app when the SIM is inserted -->
    <string name="config_carrierAppInstallDialogComponent" translatable="false"
            >com.android.simappdialog/com.android.simappdialog.InstallCarrierAppActivity</string>

    <!-- The default mobile provisioning apn. Empty by default, maybe overridden by
         an mcc/mnc specific config.xml -->
    <string name="mobile_provisioning_apn" translatable="false"></string>

    <!-- Number of retries Cell Data should attempt for a given error code before
         restarting the modem.
         Error codes not listed will not lead to modem restarts.
         Array of "code#,retry#"  -->
    <string-array name="config_cell_retries_per_error_code">
    </string-array>

    <bool name="config_auto_attach_data_on_creation">true</bool>

    <!-- Set to true if after a provisioning apn the radio should be restarted -->
    <bool name="config_restartRadioAfterProvisioning">false</bool>

    <!-- When true, indicates that the vendor's IMS implementation requires a workaround when
         sending a request to enable or disable the camera while the video session is also
         paused. -->
    <bool name="config_useVideoPauseWorkaround">false</bool>

    <!-- Use ERI text for network name on CDMA LTE -->
    <bool name="config_LTE_eri_for_network_name">true</bool>

    <!-- Flag indicating if the user is notified when the mobile network access is restricted -->
    <bool name="config_user_notification_of_restrictied_mobile_access">true</bool>

    <!-- Component name of the ICC hotswap prompt for restart dialog -->
    <string name="config_iccHotswapPromptForRestartDialogComponent" translatable="false">@null</string>

    <!-- call barring MMI code from TS 22.030 Annex B -->
    <string-array translatable="false" name="config_callBarringMMI">
        <item>33</item>
        <item>331</item>
        <item>332</item>
        <item>35</item>
        <item>351</item>
        <item>330</item>
        <item>333</item>
        <item>353</item>
    </string-array>

    <!-- Do not translate. Defines the slots is Two Digit Number for dialing normally not USSD -->
    <string-array name="config_twoDigitNumberPattern" translatable="false">
    </string-array>

    <!-- A array of regex to treat a SMS as VVM SMS if the message body matches.
         Each item represents an entry, which consists of two parts:
         a comma (,) separated list of MCCMNC the regex applies to, followed by a semicolon (;), and
         then the regex itself. -->
    <string-array name="config_vvmSmsFilterRegexes" translatable="false">
        <!-- Verizon requires any SMS that starts with //VZWVVM to be treated as a VVM SMS-->
        <item>310004,310010,310012,310013,310590,310890,310910,311110,311270,311271,311272,311273,311274,311275,311276,311277,311278,311279,311280,311281,311282,311283,311284,311285,311286,311287,311288,311289,311390,311480,311481,311482,311483,311484,311485,311486,311487,311488,311489;^//VZWVVM.*</item>
    </string-array>

    <!-- default telephony hardware configuration for this platform.
    -->
    <!-- this string array should be overridden by the device to present a list
         telephony hardware resource.  this is used by the telephony device controller
         (TDC) to offer the basic capabilities of the hardware to the telephony
         framework
    -->
    <!-- an array of "[hardware type],[hardware-uuid],[state],[[hardware-type specific]]"
         with, [[hardware-type specific]] in:
            - "[[ril-model],[rat],[max-active-voice],[max-active-data],[max-active-standby]]"
              for 'modem' hardware
            - "[[associated-modem-uuid]]"
              for 'sim' hardware.
         refer to HardwareConfig in com.android.internal.telephony for specific details/values
         those elements can carry.
    -->
    <string-array translatable="false" name="config_telephonyHardware">
        <!-- modem -->
        <item>0,modem,0,0,0,1,1,1</item>
        <!-- sim -->
        <item>1,sim,0,modem</item>
    </string-array>

    <!-- Package name for the default CellBroadcastService module [DO NOT TRANSLATE] -->
    <string name="cellbroadcast_default_package" translatable="false">com.android.cellbroadcastservice
    </string>

    <!-- For some operators, PDU has garbages. To fix it, need to use valid index -->
    <integer name="config_valid_wappush_index">-1</integer>

    <!-- Set to true if we need to not prefer an APN.
         This is being added to enable a simple scenario of pre-paid
         provisioning on some carriers, working around a bug (7305641)
         where if the preferred is used we don't try the others. -->
    <bool name="config_dontPreferApn">false</bool>

</resources>

res/values/overlayable.xml

deleted100644 → 0
+0 −78
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2020 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.
-->

<!-- The collection of resources for theming the appearance of a device -->
<resources xmlns:android="http://schemas.android.com/apk/res/android">
    <overlayable name="TelephonyCustomization">

        <!-- START VENDOR CUSTOMIZATION -->
        <policy type="product|system|vendor">
            <item type="string" name="config_mms_user_agent"/>
            <item type="string" name="config_mms_user_agent_profile_url"/>
            <item type="bool" name="config_switch_phone_on_voice_reg_state_change"/>
            <item type="bool" name="skip_restoring_network_selection"/>
            <item type="bool" name="config_hotswapCapable"/>
            <item type="array" name="config_cdma_international_roaming_indicators"/>
            <item type="integer" name="config_mobile_mtu"/>
            <item type="array" name="config_mobile_tcp_buffers"/>
            <item type="bool" name="config_use_sim_language_file"/>
            <item type="bool" name="config_requireRadioPowerOffOnSimRefreshReset"/>
            <item type="bool" name="config_device_respects_hold_carrier_config"/>
            <item type="array" name="config_display_no_service_when_sim_unready"/>
            <item type="array" name="config_telephonyEuiccDeviceCapabilities"/>
            <item type="integer" name="config_num_physical_slots"/>
            <item type="bool" name="config_duplicate_port_omadm_wappush"/>
            <item type="string" name="config_wwan_network_service_package"/>
            <item type="string" name="config_wwan_network_service_class"/>
            <item type="string" name="config_wlan_network_service_package"/>
            <item type="string" name="config_wlan_network_service_class"/>
            <item type="string" name="config_qualified_networks_service_package"/>
            <item type="string" name="config_qualified_networks_service_class"/>
            <item type="string" name="config_wwan_data_service_package"/>
            <item type="string" name="config_wwan_data_service_class"/>
            <item type="string" name="config_wlan_data_service_package"/>
            <item type="string" name="config_wlan_data_service_class"/>
            <item type="bool" name="config_use_voip_mode_for_ims"/>
            <item type="bool" name="config_built_in_sip_phone"/>
            <item type="bool" name="skipHoldBeforeMerge"/>
            <item type="bool" name="config_device_volte_available"/>
            <item type="bool" name="config_device_vt_available"/>
            <item type="bool" name="config_device_wfc_ims_available"/>
            <item type="bool" name="config_dynamic_bind_ims"/>
            <item type="string" name="config_ims_package"/>
            <item type="string" name="config_carrierAppInstallDialogComponent"/>
            <item type="bool" name="config_cbrs_supported"/>
            <item type="bool" name="config_sip_wifi_only"/>
            <item type="string" name="mobile_provisioning_apn"/>
            <item type="array" name="config_cell_retries_per_error_code"/>
            <item type="bool" name="config_auto_attach_data_on_creation"/>
            <item type="bool" name="config_restartRadioAfterProvisioning"/>
            <item type="bool" name="config_useVideoPauseWorkaround"/>
            <item type="bool" name="config_LTE_eri_for_network_name"/>
            <item type="bool" name="config_user_notification_of_restrictied_mobile_access"/>
            <item type="string" name="config_iccHotswapPromptForRestartDialogComponent"/>
            <item type="array" name="config_callBarringMMI"/>
            <item type="array" name="config_twoDigitNumberPattern"/>
            <item type="array" name="config_vvmSmsFilterRegexes"/>
            <item type="array" name="config_telephonyHardware"/>
            <item type="string" name="cellbroadcast_default_package"/>
            <item type="integer" name="config_valid_wappush_index"/>
            <item type="bool" name="config_dontPreferApn"/>
          </policy>
        <!-- END VENDOR CUSTOMIZATION -->

    </overlayable>
</resources>

res/values/strings.xml

deleted100644 → 0
+0 −412

File deleted.

Preview size limit exceeded, changes collapsed.

+0 −43
Original line number Diff line number Diff line
/*
 * Copyright (C) 2020 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.
 */
package com.android.internal.telephony.util;

import android.content.Context;
import android.content.pm.PackageManager;
import android.content.res.Resources;

import com.android.telephony.Rlog;

/**
 * This class provides utility functions for Telephony Resources
 */
public final class TelephonyResourceUtils {
    public static String TELEPHONY_RESOURCE_PACKAGE = "com.android.telephony.resources";
    private static final String TAG = "TelephonyResourceUtils";

    /**
     * Retrieve resource for the telephony resource package.
     */
    public static Resources getTelephonyResources(Context context) {
        try {
            return context.getPackageManager()
                    .getResourcesForApplication(TELEPHONY_RESOURCE_PACKAGE);
        }  catch (PackageManager.NameNotFoundException ex) {
            Rlog.e(TAG, "No resource package found");
        }
        return null;
    }
}
Loading