Loading telephony/java/android/telephony/TelephonyManager.java +23 −0 Original line number Diff line number Diff line Loading @@ -8400,6 +8400,29 @@ public class TelephonyManager { return false; } /** * Checks if manual network selection is allowed. * * <p>If this object has been created with {@link #createForSubscriptionId}, applies to the * given subId. Otherwise, applies to {@link SubscriptionManager#getDefaultSubscriptionId()}. * * @return {@code true} if manual network selection is allowed, otherwise return {@code false}. * * @hide */ @RequiresPermission(android.Manifest.permission.READ_PHONE_STATE) public boolean isManualNetworkSelectionAllowed() { try { ITelephony telephony = getITelephony(); if (telephony != null) { return telephony.isManualNetworkSelectionAllowed(getSubId()); } } catch (RemoteException e) { Log.e(TAG, "Error calling ITelephony#isManualNetworkSelectionAllowed", e); } return true; } /** * Get the most recently available signal strength information. * Loading telephony/java/com/android/internal/telephony/ITelephony.aidl +7 −0 Original line number Diff line number Diff line Loading @@ -808,6 +808,13 @@ interface ITelephony { */ boolean isDataEnabled(int subId); /** * Checks if manual network selection is allowed. * * @return {@code true} if manual network selection is allowed, otherwise return {@code false}. */ boolean isManualNetworkSelectionAllowed(int subId); /** * Get P-CSCF address from PCO after data connection is established or modified. * @param apnType the apnType, "ims" for IMS APN, "emergency" for EMERGENCY APN Loading Loading
telephony/java/android/telephony/TelephonyManager.java +23 −0 Original line number Diff line number Diff line Loading @@ -8400,6 +8400,29 @@ public class TelephonyManager { return false; } /** * Checks if manual network selection is allowed. * * <p>If this object has been created with {@link #createForSubscriptionId}, applies to the * given subId. Otherwise, applies to {@link SubscriptionManager#getDefaultSubscriptionId()}. * * @return {@code true} if manual network selection is allowed, otherwise return {@code false}. * * @hide */ @RequiresPermission(android.Manifest.permission.READ_PHONE_STATE) public boolean isManualNetworkSelectionAllowed() { try { ITelephony telephony = getITelephony(); if (telephony != null) { return telephony.isManualNetworkSelectionAllowed(getSubId()); } } catch (RemoteException e) { Log.e(TAG, "Error calling ITelephony#isManualNetworkSelectionAllowed", e); } return true; } /** * Get the most recently available signal strength information. * Loading
telephony/java/com/android/internal/telephony/ITelephony.aidl +7 −0 Original line number Diff line number Diff line Loading @@ -808,6 +808,13 @@ interface ITelephony { */ boolean isDataEnabled(int subId); /** * Checks if manual network selection is allowed. * * @return {@code true} if manual network selection is allowed, otherwise return {@code false}. */ boolean isManualNetworkSelectionAllowed(int subId); /** * Get P-CSCF address from PCO after data connection is established or modified. * @param apnType the apnType, "ims" for IMS APN, "emergency" for EMERGENCY APN Loading