diff options
| author | Jackal Guo <jackalguo@google.com> | 2021-04-22 08:54:29 +0000 |
|---|---|---|
| committer | Android (Google) Code Review <android-gerrit@google.com> | 2021-04-22 08:54:29 +0000 |
| commit | 011805bf48366fe521e1b58c29873cd6d2f9432c (patch) | |
| tree | 11aad18231edb05b31c3f1f30f0b2bb072c0f950 /core/java/android | |
| parent | b63dedbb2db881b99f848aab446a0dfa0d3ece52 (diff) | |
| parent | a3e316fb0153cb4d4cf4f154e0bb85a9a543d6a5 (diff) | |
Merge "Apply package visibility to LauncherApps.Callback" into sc-dev
Diffstat (limited to 'core/java/android')
| -rw-r--r-- | core/java/android/content/Intent.java | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/core/java/android/content/Intent.java b/core/java/android/content/Intent.java index 71cd6f1ec49c..39933a9ee7b4 100644 --- a/core/java/android/content/Intent.java +++ b/core/java/android/content/Intent.java @@ -2569,6 +2569,32 @@ public class Intent implements Parcelable, Cloneable { @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION) public static final String ACTION_PACKAGE_REMOVED = "android.intent.action.PACKAGE_REMOVED"; /** + * Broadcast Action: An existing application package has been removed from + * the device. The data contains the name of the package and the visibility + * allow list. The package that is being removed does <em>not</em> receive + * this Intent. + * <ul> + * <li> {@link #EXTRA_UID} containing the integer uid previously assigned + * to the package. + * <li> {@link #EXTRA_DATA_REMOVED} is set to true if the entire + * application -- data and code -- is being removed. + * <li> {@link #EXTRA_REPLACING} is set to true if this will be followed + * by an {@link #ACTION_PACKAGE_ADDED} broadcast for the same package. + * <li> {@link #EXTRA_USER_INITIATED} containing boolean field to signal + * that the application was removed with the user-initiated action. + * <li> {@link #EXTRA_VISIBILITY_ALLOW_LIST} containing an int array to + * indicate the visibility allow list. + * </ul> + * + * <p class="note">This is a protected intent that can only be sent + * by the system. + * + * @hide This broadcast is used internally by the system. + */ + @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION) + public static final String ACTION_PACKAGE_REMOVED_INTERNAL = + "android.intent.action.PACKAGE_REMOVED_INTERNAL"; + /** * Broadcast Action: An existing application package has been completely * removed from the device. The data contains the name of the package. * This is like {@link #ACTION_PACKAGE_REMOVED}, but only set when @@ -6122,6 +6148,16 @@ public class Intent implements Parcelable, Cloneable { */ public static final String EXTRA_LOCUS_ID = "android.intent.extra.LOCUS_ID"; + /** + * Used as an int array extra field in + * {@link android.content.Intent#ACTION_PACKAGE_REMOVED_INTERNAL} + * intents to indicate that visibility allow list of this removed package. + * + * @hide + */ + public static final String EXTRA_VISIBILITY_ALLOW_LIST = + "android.intent.extra.VISIBILITY_ALLOW_LIST"; + // --------------------------------------------------------------------- // --------------------------------------------------------------------- // Intent flags (see mFlags variable). |
