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

Commit fcbda454 authored by Jack Yu's avatar Jack Yu
Browse files

Added data service configuration support

Added the resource overlay and carrier config support for
data service binding package configuration.

Test: Telephony sanity tests
Bug: 64132030
Change-Id: I3d64e6c0a5f86b6a4953eb611ee6828153a8b12d
parent cb9cd96c
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -2468,6 +2468,14 @@
    <!-- Flag specifying whether or not IMS will use the dynamic ImsResolver -->
    <bool name="config_dynamic_bind_ims">false</bool>

    <!-- 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>

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

    <!-- Home (non-roaming) values for CDMA roaming indicator.
+2 −0
Original line number Diff line number Diff line
@@ -264,6 +264,8 @@
  <java-symbol type="bool" name="config_mms_content_disposition_support" />
  <java-symbol type="string" name="config_ims_package" />
  <java-symbol type="bool" name="config_dynamic_bind_ims" />
  <java-symbol type="string" name="config_wwan_data_service_package" />
  <java-symbol type="string" name="config_wlan_data_service_package" />
  <java-symbol type="bool" name="config_networkSamplingWakesDevice" />
  <java-symbol type="bool" name="config_showMenuShortcutsWhenKeyboardPresent" />
  <java-symbol type="bool" name="config_sip_wifi_only" />
+16 −0
Original line number Diff line number Diff line
@@ -491,6 +491,20 @@ public class CarrierConfigManager {
    public static final String KEY_CARRIER_VOLTE_OVERRIDE_WFC_PROVISIONING_BOOL
            = "carrier_volte_override_wfc_provisioning_bool";

    /**
     * Override the device's configuration for the cellular data service to use for this SIM card.
     * @hide
     */
    public static final String KEY_CARRIER_DATA_SERVICE_WWAN_PACKAGE_OVERRIDE_STRING
            = "carrier_data_service_wwan_package_override_string";

    /**
     * Override the device's configuration for the IWLAN data service to use for this SIM card.
     * @hide
     */
    public static final String KEY_CARRIER_DATA_SERVICE_WLAN_PACKAGE_OVERRIDE_STRING
            = "carrier_data_service_wlan_package_override_string";

    /** Flag specifying whether VoLTE TTY is supported. */
    public static final String KEY_CARRIER_VOLTE_TTY_SUPPORTED_BOOL
            = "carrier_volte_tty_supported_bool";
@@ -1797,6 +1811,8 @@ public class CarrierConfigManager {
        sDefaults.putBoolean(KEY_CARRIER_IMS_GBA_REQUIRED_BOOL, false);
        sDefaults.putBoolean(KEY_CARRIER_INSTANT_LETTERING_AVAILABLE_BOOL, false);
        sDefaults.putBoolean(KEY_CARRIER_USE_IMS_FIRST_FOR_EMERGENCY_BOOL, true);
        sDefaults.putString(KEY_CARRIER_DATA_SERVICE_WWAN_PACKAGE_OVERRIDE_STRING, "");
        sDefaults.putString(KEY_CARRIER_DATA_SERVICE_WLAN_PACKAGE_OVERRIDE_STRING, "");
        sDefaults.putString(KEY_CARRIER_INSTANT_LETTERING_INVALID_CHARS_STRING, "");
        sDefaults.putString(KEY_CARRIER_INSTANT_LETTERING_ESCAPED_CHARS_STRING, "");
        sDefaults.putString(KEY_CARRIER_INSTANT_LETTERING_ENCODING_STRING, "");
+5 −1
Original line number Diff line number Diff line
@@ -34,6 +34,8 @@ import android.telephony.AccessNetworkConstants;
import android.telephony.Rlog;
import android.util.SparseArray;

import com.android.internal.annotations.VisibleForTesting;

import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.util.ArrayList;
@@ -105,7 +107,9 @@ public abstract class DataService extends Service {

    private final SparseArray<DataServiceProvider> mServiceMap = new SparseArray<>();

    private final IBinder mBinder = new IDataServiceWrapper();
    /** @hide */
    @VisibleForTesting
    public final IDataServiceWrapper mBinder = new IDataServiceWrapper();

    /**
     * The abstract class of the actual data service implementation. The data service provider
+1 −0
Original line number Diff line number Diff line
@@ -108,6 +108,7 @@ public class DctConstants {
    public static final int EVENT_SET_CARRIER_DATA_ENABLED = BASE + 46;
    public static final int EVENT_DATA_RECONNECT = BASE + 47;
    public static final int EVENT_ROAMING_SETTING_CHANGE = BASE + 48;
    public static final int EVENT_DATA_SERVICE_BINDING_CHANGED = BASE + 49;

    /***** Constants *****/