summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Patrick Huang <pinchin@google.com> 2019-03-21 17:11:04 -0700
committer android-build-merger <android-build-merger@google.com> 2019-03-21 17:11:04 -0700
commit956b77b87ad0e396738df281b5dbaae5748afed2 (patch)
tree1ab75eeac1271849e359de6f2dbde79709118a10
parentd710627c77ed14c6d5a9180def873ef3144c166b (diff)
parente41be2c8765193e6c12419743a43d48bc9d6a9bf (diff)
Merge "Add "from" extra for ACTION_TOGGLE_SUBSCRIPTION_PRIVILEGED" am: 9a1888ce62
am: e41be2c876 Change-Id: I6f343eafd8379253d274c98a9097df50976b9522
-rw-r--r--api/system-current.txt1
-rw-r--r--telephony/java/android/telephony/euicc/EuiccManager.java24
2 files changed, 21 insertions, 4 deletions
diff --git a/api/system-current.txt b/api/system-current.txt
index f5c41b6f8a30..f8038a59c438 100644
--- a/api/system-current.txt
+++ b/api/system-current.txt
@@ -6689,6 +6689,7 @@ package android.telephony.euicc {
field public static final int EUICC_OTA_SUCCEEDED = 3; // 0x3
field public static final String EXTRA_EMBEDDED_SUBSCRIPTION_DOWNLOADABLE_SUBSCRIPTIONS = "android.telephony.euicc.extra.EMBEDDED_SUBSCRIPTION_DOWNLOADABLE_SUBSCRIPTIONS";
field public static final String EXTRA_ENABLE_SUBSCRIPTION = "android.telephony.euicc.extra.ENABLE_SUBSCRIPTION";
+ field public static final String EXTRA_FROM_SUBSCRIPTION_ID = "android.telephony.euicc.extra.FROM_SUBSCRIPTION_ID";
field public static final String EXTRA_SUBSCRIPTION_ID = "android.telephony.euicc.extra.SUBSCRIPTION_ID";
field public static final String EXTRA_SUBSCRIPTION_NICKNAME = "android.telephony.euicc.extra.SUBSCRIPTION_NICKNAME";
}
diff --git a/telephony/java/android/telephony/euicc/EuiccManager.java b/telephony/java/android/telephony/euicc/EuiccManager.java
index 12ad140a64b5..f1a5778b2281 100644
--- a/telephony/java/android/telephony/euicc/EuiccManager.java
+++ b/telephony/java/android/telephony/euicc/EuiccManager.java
@@ -119,9 +119,9 @@ public class EuiccManager {
/**
* Intent action sent by system apps (such as the Settings app) to the Telephony framework to
* enable or disable a subscription. Must be accompanied with {@link #EXTRA_SUBSCRIPTION_ID} and
- * {@link #EXTRA_ENABLE_SUBSCRIPTION}.
+ * {@link #EXTRA_ENABLE_SUBSCRIPTION}, and optionally {@link #EXTRA_FROM_SUBSCRIPTION_ID}.
*
- * Requires the caller to be a privileged process with the
+ * <p>Requires the caller to be a privileged process with the
* {@link android.permission#CALL_PRIVILEGED} permission for the intent to reach the Telephony
* stack.
*
@@ -144,7 +144,7 @@ public class EuiccManager {
* Intent action sent by system apps (such as the Settings app) to the Telephony framework to
* delete a subscription. Must be accompanied with {@link #EXTRA_SUBSCRIPTION_ID}.
*
- * Requires the caller to be a privileged process with the
+ * <p>Requires the caller to be a privileged process with the
* {@link android.permission#CALL_PRIVILEGED} permission for the intent to reach the Telephony
* stack.
*
@@ -168,7 +168,7 @@ public class EuiccManager {
* rename a subscription. Must be accompanied with {@link #EXTRA_SUBSCRIPTION_ID} and
* {@link #EXTRA_SUBSCRIPTION_NICKNAME}.
*
- * Requires the caller to be a privileged process with the
+ * <p>Requires the caller to be a privileged process with the
* {@link android.permission#CALL_PRIVILEGED} permission for the intent to reach the Telephony
* stack.
*
@@ -305,6 +305,22 @@ public class EuiccManager {
"android.telephony.euicc.extra.SUBSCRIPTION_NICKNAME";
/**
+ * Key for an extra set on {@link #ACTION_TOGGLE_SUBSCRIPTION_PRIVILEGED} providing the ID of
+ * the subscription we're toggling from. This extra is optional and is only used for UI
+ * purposes by the underlying eUICC service (i.e. the LPA app), such as displaying a dialog
+ * titled "Switch X with Y". If set, the provided subscription will be used as the "from"
+ * subscription in UI (the "X" in the dialog example). Otherwise, the currently active
+ * subscription that will be disabled is the "from" subscription.
+ *
+ * <p>Expected type of the extra data: int
+ *
+ * @hide
+ */
+ @SystemApi
+ public static final String EXTRA_FROM_SUBSCRIPTION_ID =
+ "android.telephony.euicc.extra.FROM_SUBSCRIPTION_ID";
+
+ /**
* Optional meta-data attribute for a carrier app providing an icon to use to represent the
* carrier. If not provided, the app's launcher icon will be used as a fallback.
*/