summaryrefslogtreecommitdiffstats
path: root/telephony/java
diff options
context:
space:
mode:
authorAndrew Flynn <flynn@google.com>2015-06-08 19:59:50 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2015-06-08 19:59:51 +0000
commit21a4f17c942165684bc590de594984912459396d (patch)
tree24ce5e0d91467ca61f4a8b6703e883981692f235 /telephony/java
parent54d729b73f54798d3112129894cb6fe8ef75920b (diff)
parent2b5348b41329b42f5b0929455a9b616a5e1f685e (diff)
downloadframeworks_base-21a4f17c942165684bc590de594984912459396d.zip
frameworks_base-21a4f17c942165684bc590de594984912459396d.tar.gz
frameworks_base-21a4f17c942165684bc590de594984912459396d.tar.bz2
Merge "Revert "notifyCarrierNetworkChange:TelephonyManager->CarrierService"" into mnc-dev
Diffstat (limited to 'telephony/java')
-rw-r--r--telephony/java/android/telephony/TelephonyManager.java29
1 files changed, 29 insertions, 0 deletions
diff --git a/telephony/java/android/telephony/TelephonyManager.java b/telephony/java/android/telephony/TelephonyManager.java
index 64be410..f5a7c0f 100644
--- a/telephony/java/android/telephony/TelephonyManager.java
+++ b/telephony/java/android/telephony/TelephonyManager.java
@@ -2082,6 +2082,35 @@ public class TelephonyManager {
}
/**
+ * Informs the system of an intentional upcoming carrier network change by
+ * a carrier app. This call is optional and is only used to allow the
+ * system to provide alternative UI while telephony is performing an action
+ * that may result in intentional, temporary network lack of connectivity.
+ * <p>
+ * Based on the active parameter passed in, this method will either show or
+ * hide the alternative UI. There is no timeout associated with showing
+ * this UX, so a carrier app must be sure to call with active set to false
+ * sometime after calling with it set to true.
+ * <p>
+ * Requires Permission:
+ * {@link android.Manifest.permission#MODIFY_PHONE_STATE MODIFY_PHONE_STATE}
+ * Or the calling app has carrier privileges.
+ * @see #hasCarrierPrivileges
+ *
+ * @param active Whether the carrier network change is or shortly will be
+ * active. Set this value to true to begin showing
+ * alternative UI and false to stop.
+ */
+ public void notifyCarrierNetworkChange(boolean active) {
+ try {
+ if (sRegistry != null)
+ sRegistry.notifyCarrierNetworkChange(active);
+ } catch (RemoteException ex) {
+ } catch (NullPointerException ex) {
+ }
+ }
+
+ /**
* Returns the alphabetic identifier associated with the line 1 number.
* Return null if it is unavailable.
* <p>