Loading core/java/android/net/NetworkMisc.java +12 −0 Original line number Diff line number Diff line Loading @@ -51,6 +51,15 @@ public class NetworkMisc implements Parcelable { */ public boolean acceptUnvalidated; /** * Set to avoid surfacing the "Sign in to network" notification. * if carrier receivers/apps are registered to handle the carrier-specific provisioning * procedure, a carrier specific provisioning notification will be placed. * only one notification should be displayed. This field is set based on * which notification should be used for provisioning. */ public boolean provisioningNotificationDisabled; /** * For mobile networks, this is the subscriber ID (such as IMSI). */ Loading @@ -65,6 +74,7 @@ public class NetworkMisc implements Parcelable { explicitlySelected = nm.explicitlySelected; acceptUnvalidated = nm.acceptUnvalidated; subscriberId = nm.subscriberId; provisioningNotificationDisabled = nm.provisioningNotificationDisabled; } } Loading @@ -79,6 +89,7 @@ public class NetworkMisc implements Parcelable { out.writeInt(explicitlySelected ? 1 : 0); out.writeInt(acceptUnvalidated ? 1 : 0); out.writeString(subscriberId); out.writeInt(provisioningNotificationDisabled ? 1 : 0); } public static final Creator<NetworkMisc> CREATOR = new Creator<NetworkMisc>() { Loading @@ -89,6 +100,7 @@ public class NetworkMisc implements Parcelable { networkMisc.explicitlySelected = in.readInt() != 0; networkMisc.acceptUnvalidated = in.readInt() != 0; networkMisc.subscriberId = in.readString(); networkMisc.provisioningNotificationDisabled = in.readInt() != 0; return networkMisc; } Loading packages/SystemUI/src/com/android/systemui/statusbar/policy/NetworkControllerImpl.java +1 −1 Original line number Diff line number Diff line Loading @@ -810,7 +810,7 @@ public class NetworkControllerImpl extends BroadcastReceiver private SubscriptionInfo addSignalController(int id, int simSlotIndex) { SubscriptionInfo info = new SubscriptionInfo(id, "", simSlotIndex, "", "", 0, 0, "", 0, null, 0, 0, "", SubscriptionManager.SIM_PROVISIONED); null, 0, 0, ""); mMobileSignalControllers.put(id, new MobileSignalController(mContext, mConfig, mHasMobileDataFeature, mPhone, mCallbackHandler, this, info, mSubDefaults, mReceiverHandler.getLooper())); Loading services/core/java/com/android/server/ConnectivityService.java +6 −3 Original line number Diff line number Diff line Loading @@ -2150,10 +2150,12 @@ public class ConnectivityService extends IConnectivityManager.Stub loge("EVENT_PROVISIONING_NOTIFICATION from unknown NetworkMonitor"); break; } if (!nai.networkMisc.provisioningNotificationDisabled) { setProvNotificationVisibleIntent(true, netId, NotificationType.SIGN_IN, nai.networkInfo.getType(), nai.networkInfo.getExtraInfo(), (PendingIntent)msg.obj, nai.networkMisc.explicitlySelected); } } break; } } Loading Loading @@ -2553,6 +2555,7 @@ public class ConnectivityService extends IConnectivityManager.Stub PendingIntent pendingIntent = PendingIntent.getActivityAsUser( mContext, 0, intent, PendingIntent.FLAG_CANCEL_CURRENT, null, UserHandle.CURRENT); setProvNotificationVisibleIntent(true, nai.network.netId, NotificationType.NO_INTERNET, nai.networkInfo.getType(), nai.networkInfo.getExtraInfo(), pendingIntent, true); } Loading services/core/java/com/android/server/connectivity/NetworkMonitor.java +1 −2 Original line number Diff line number Diff line Loading @@ -66,7 +66,6 @@ import com.android.internal.util.Protocol; import com.android.internal.util.State; import com.android.internal.util.StateMachine; import com.android.internal.util.WakeupMessage; import com.android.server.connectivity.NetworkAgentInfo; import java.io.IOException; import java.net.HttpURLConnection; Loading telephony/java/android/telephony/CarrierConfigManager.java +33 −13 Original line number Diff line number Diff line Loading @@ -675,18 +675,37 @@ public class CarrierConfigManager { public static final String KEY_MMS_USER_AGENT_STRING = "userAgent"; /** * If carriers require differentiate un-provisioned status: cold sim or out of credit sim * a package name and activity name can be provided to launch a supported carrier application * that check the sim provisioning status * The first element is the package name and the second element is the activity name * of the provisioning app * example: * <item>com.google.android.carrierPackageName</item> * <item>com.google.android.carrierPackageName.CarrierActivityName</item> * A list of component name of carrier signalling receivers which are interested in intent * android.intent.action.CARRIER_SIGNAL_REDIRECTED. * Example: * <item>com.google.android.carrierPackageName/.CarrierSignalReceiverNameA</item> * <item>com.google.android.carrierPackageName/.CarrierSignalReceiverNameB</item> * @hide */ public static final String KEY_SIM_PROVISIONING_STATUS_DETECTION_CARRIER_APP_STRING_ARRAY = "sim_state_detection_carrier_app_string_array"; public static final String KEY_SIGNAL_REDIRECTION_RECEIVER_STRING_ARRAY = "signal_redirection_receiver_string_array"; /** * A list of component name of carrier signalling receivers which are interested in intent * android.intent.action.CARRIER_SIGNAL_REQUEST_NETWORK_FAILED. * Example: * <item>com.google.android.carrierPackageName/.CarrierSignalReceiverNameA</item> * <item>com.google.android.carrierPackageName/.CarrierSignalReceiverNameB</item> * @hide */ public static final String KEY_SIGNAL_DCFAILURE_RECEIVER_STRING_ARRAY = "signal_dcfailure_receiver_string_array"; /** * A list of component name of carrier signalling receivers which are interested in intent * android.intent.action.CARRIER_SIGNAL_PCO_VALUE. * Example: * <item>com.google.android.carrierPackageName/.CarrierSignalReceiverNameA</item> * <item>com.google.android.carrierPackageName/.CarrierSignalReceiverNameB</item> * @hide */ public static final String KEY_SIGNAL_PCO_RECEIVER_STRING_ARRAY = "signal_pco_receiver_string_array"; /** * Determines whether the carrier supports making non-emergency phone calls while the phone is Loading Loading @@ -864,9 +883,10 @@ public class CarrierConfigManager { sDefaults.putBoolean(KEY_ALLOW_NON_EMERGENCY_CALLS_IN_ECM_BOOL, true); sDefaults.putBoolean(KEY_USE_RCS_PRESENCE_BOOL, false); // Used for Sim card State detection app sDefaults.putStringArray(KEY_SIM_PROVISIONING_STATUS_DETECTION_CARRIER_APP_STRING_ARRAY, null); // Carrier Signalling Receivers sDefaults.putStringArray(KEY_SIGNAL_REDIRECTION_RECEIVER_STRING_ARRAY, null); sDefaults.putStringArray(KEY_SIGNAL_DCFAILURE_RECEIVER_STRING_ARRAY, null); sDefaults.putStringArray(KEY_SIGNAL_PCO_RECEIVER_STRING_ARRAY, null); } /** Loading Loading
core/java/android/net/NetworkMisc.java +12 −0 Original line number Diff line number Diff line Loading @@ -51,6 +51,15 @@ public class NetworkMisc implements Parcelable { */ public boolean acceptUnvalidated; /** * Set to avoid surfacing the "Sign in to network" notification. * if carrier receivers/apps are registered to handle the carrier-specific provisioning * procedure, a carrier specific provisioning notification will be placed. * only one notification should be displayed. This field is set based on * which notification should be used for provisioning. */ public boolean provisioningNotificationDisabled; /** * For mobile networks, this is the subscriber ID (such as IMSI). */ Loading @@ -65,6 +74,7 @@ public class NetworkMisc implements Parcelable { explicitlySelected = nm.explicitlySelected; acceptUnvalidated = nm.acceptUnvalidated; subscriberId = nm.subscriberId; provisioningNotificationDisabled = nm.provisioningNotificationDisabled; } } Loading @@ -79,6 +89,7 @@ public class NetworkMisc implements Parcelable { out.writeInt(explicitlySelected ? 1 : 0); out.writeInt(acceptUnvalidated ? 1 : 0); out.writeString(subscriberId); out.writeInt(provisioningNotificationDisabled ? 1 : 0); } public static final Creator<NetworkMisc> CREATOR = new Creator<NetworkMisc>() { Loading @@ -89,6 +100,7 @@ public class NetworkMisc implements Parcelable { networkMisc.explicitlySelected = in.readInt() != 0; networkMisc.acceptUnvalidated = in.readInt() != 0; networkMisc.subscriberId = in.readString(); networkMisc.provisioningNotificationDisabled = in.readInt() != 0; return networkMisc; } Loading
packages/SystemUI/src/com/android/systemui/statusbar/policy/NetworkControllerImpl.java +1 −1 Original line number Diff line number Diff line Loading @@ -810,7 +810,7 @@ public class NetworkControllerImpl extends BroadcastReceiver private SubscriptionInfo addSignalController(int id, int simSlotIndex) { SubscriptionInfo info = new SubscriptionInfo(id, "", simSlotIndex, "", "", 0, 0, "", 0, null, 0, 0, "", SubscriptionManager.SIM_PROVISIONED); null, 0, 0, ""); mMobileSignalControllers.put(id, new MobileSignalController(mContext, mConfig, mHasMobileDataFeature, mPhone, mCallbackHandler, this, info, mSubDefaults, mReceiverHandler.getLooper())); Loading
services/core/java/com/android/server/ConnectivityService.java +6 −3 Original line number Diff line number Diff line Loading @@ -2150,10 +2150,12 @@ public class ConnectivityService extends IConnectivityManager.Stub loge("EVENT_PROVISIONING_NOTIFICATION from unknown NetworkMonitor"); break; } if (!nai.networkMisc.provisioningNotificationDisabled) { setProvNotificationVisibleIntent(true, netId, NotificationType.SIGN_IN, nai.networkInfo.getType(), nai.networkInfo.getExtraInfo(), (PendingIntent)msg.obj, nai.networkMisc.explicitlySelected); } } break; } } Loading Loading @@ -2553,6 +2555,7 @@ public class ConnectivityService extends IConnectivityManager.Stub PendingIntent pendingIntent = PendingIntent.getActivityAsUser( mContext, 0, intent, PendingIntent.FLAG_CANCEL_CURRENT, null, UserHandle.CURRENT); setProvNotificationVisibleIntent(true, nai.network.netId, NotificationType.NO_INTERNET, nai.networkInfo.getType(), nai.networkInfo.getExtraInfo(), pendingIntent, true); } Loading
services/core/java/com/android/server/connectivity/NetworkMonitor.java +1 −2 Original line number Diff line number Diff line Loading @@ -66,7 +66,6 @@ import com.android.internal.util.Protocol; import com.android.internal.util.State; import com.android.internal.util.StateMachine; import com.android.internal.util.WakeupMessage; import com.android.server.connectivity.NetworkAgentInfo; import java.io.IOException; import java.net.HttpURLConnection; Loading
telephony/java/android/telephony/CarrierConfigManager.java +33 −13 Original line number Diff line number Diff line Loading @@ -675,18 +675,37 @@ public class CarrierConfigManager { public static final String KEY_MMS_USER_AGENT_STRING = "userAgent"; /** * If carriers require differentiate un-provisioned status: cold sim or out of credit sim * a package name and activity name can be provided to launch a supported carrier application * that check the sim provisioning status * The first element is the package name and the second element is the activity name * of the provisioning app * example: * <item>com.google.android.carrierPackageName</item> * <item>com.google.android.carrierPackageName.CarrierActivityName</item> * A list of component name of carrier signalling receivers which are interested in intent * android.intent.action.CARRIER_SIGNAL_REDIRECTED. * Example: * <item>com.google.android.carrierPackageName/.CarrierSignalReceiverNameA</item> * <item>com.google.android.carrierPackageName/.CarrierSignalReceiverNameB</item> * @hide */ public static final String KEY_SIM_PROVISIONING_STATUS_DETECTION_CARRIER_APP_STRING_ARRAY = "sim_state_detection_carrier_app_string_array"; public static final String KEY_SIGNAL_REDIRECTION_RECEIVER_STRING_ARRAY = "signal_redirection_receiver_string_array"; /** * A list of component name of carrier signalling receivers which are interested in intent * android.intent.action.CARRIER_SIGNAL_REQUEST_NETWORK_FAILED. * Example: * <item>com.google.android.carrierPackageName/.CarrierSignalReceiverNameA</item> * <item>com.google.android.carrierPackageName/.CarrierSignalReceiverNameB</item> * @hide */ public static final String KEY_SIGNAL_DCFAILURE_RECEIVER_STRING_ARRAY = "signal_dcfailure_receiver_string_array"; /** * A list of component name of carrier signalling receivers which are interested in intent * android.intent.action.CARRIER_SIGNAL_PCO_VALUE. * Example: * <item>com.google.android.carrierPackageName/.CarrierSignalReceiverNameA</item> * <item>com.google.android.carrierPackageName/.CarrierSignalReceiverNameB</item> * @hide */ public static final String KEY_SIGNAL_PCO_RECEIVER_STRING_ARRAY = "signal_pco_receiver_string_array"; /** * Determines whether the carrier supports making non-emergency phone calls while the phone is Loading Loading @@ -864,9 +883,10 @@ public class CarrierConfigManager { sDefaults.putBoolean(KEY_ALLOW_NON_EMERGENCY_CALLS_IN_ECM_BOOL, true); sDefaults.putBoolean(KEY_USE_RCS_PRESENCE_BOOL, false); // Used for Sim card State detection app sDefaults.putStringArray(KEY_SIM_PROVISIONING_STATUS_DETECTION_CARRIER_APP_STRING_ARRAY, null); // Carrier Signalling Receivers sDefaults.putStringArray(KEY_SIGNAL_REDIRECTION_RECEIVER_STRING_ARRAY, null); sDefaults.putStringArray(KEY_SIGNAL_DCFAILURE_RECEIVER_STRING_ARRAY, null); sDefaults.putStringArray(KEY_SIGNAL_PCO_RECEIVER_STRING_ARRAY, null); } /** Loading