Fields Summary |
---|
private static final IntentCompatImpl | IMPL |
public static final String | ACTION_EXTERNAL_APPLICATIONS_AVAILABLEBroadcast Action: Resources for a set of packages (which were
previously unavailable) are currently
available since the media on which they exist is available.
The extra data {@link #EXTRA_CHANGED_PACKAGE_LIST} contains a
list of packages whose availability changed.
The extra data {@link #EXTRA_CHANGED_UID_LIST} contains a
list of uids of packages whose availability changed.
Note that the
packages in this list do not receive this broadcast.
The specified set of packages are now available on the system.
Includes the following extras:
- {@link #EXTRA_CHANGED_PACKAGE_LIST} is the set of packages
whose resources(were previously unavailable) are currently available.
{@link #EXTRA_CHANGED_UID_LIST} is the set of uids of the
packages whose resources(were previously unavailable)
are currently available.
This is a protected intent that can only be sent
by the system. |
public static final String | ACTION_EXTERNAL_APPLICATIONS_UNAVAILABLEBroadcast Action: Resources for a set of packages are currently
unavailable since the media on which they exist is unavailable.
The extra data {@link #EXTRA_CHANGED_PACKAGE_LIST} contains a
list of packages whose availability changed.
The extra data {@link #EXTRA_CHANGED_UID_LIST} contains a
list of uids of packages whose availability changed.
The specified set of packages can no longer be
launched and are practically unavailable on the system.
Inclues the following extras:
- {@link #EXTRA_CHANGED_PACKAGE_LIST} is the set of packages
whose resources are no longer available.
{@link #EXTRA_CHANGED_UID_LIST} is the set of packages
whose resources are no longer available.
This is a protected intent that can only be sent
by the system. |
public static final String | EXTRA_CHANGED_PACKAGE_LISTThis field is part of
{@link android.content.Intent#ACTION_EXTERNAL_APPLICATIONS_AVAILABLE},
{@link android.content.Intent#ACTION_EXTERNAL_APPLICATIONS_UNAVAILABLE}
and contains a string array of all of the components that have changed. |
public static final String | EXTRA_CHANGED_UID_LISTThis field is part of
{@link android.content.Intent#ACTION_EXTERNAL_APPLICATIONS_AVAILABLE},
{@link android.content.Intent#ACTION_EXTERNAL_APPLICATIONS_UNAVAILABLE}
and contains an integer array of uids of all of the components
that have changed. |
public static final String | EXTRA_HTML_TEXTA constant String that is associated with the Intent, used with
{@link android.content.Intent#ACTION_SEND} to supply an alternative to
{@link android.content.Intent#EXTRA_TEXT}
as HTML formatted text. Note that you must also supply
{@link android.content.Intent#EXTRA_TEXT}. |
public static final int | FLAG_ACTIVITY_TASK_ON_HOMEIf set in an Intent passed to {@link Context#startActivity Context.startActivity()},
this flag will cause a newly launching task to be placed on top of the current
home activity task (if there is one). That is, pressing back from the task
will always return the user to home even if that was not the last activity they
saw. This can only be used in conjunction with
{@link android.content.Intent#FLAG_ACTIVITY_NEW_TASK}. |
public static final int | FLAG_ACTIVITY_CLEAR_TASKIf set in an Intent passed to {@link Context#startActivity Context.startActivity()},
this flag will cause any existing task that would be associated with the
activity to be cleared before the activity is started. That is, the activity
becomes the new root of an otherwise empty task, and any old activities
are finished. This can only be used in conjunction with
{@link android.content.Intent#FLAG_ACTIVITY_NEW_TASK}.
This flag will only be obeyed on devices supporting API 11 or higher. |
Methods Summary |
---|
public static android.content.Intent | makeMainActivity(android.content.ComponentName mainActivity)Create an intent to launch the main (root) activity of a task. This
is the Intent that is started when the application's is launched from
Home. For anything else that wants to launch an application in the
same way, it is important that they use an Intent structured the same
way, and can use this function to ensure this is the case.
The returned Intent has the given Activity component as its explicit
component, {@link Intent#ACTION_MAIN ACTION_MAIN} as its action, and includes the
category {@link Intent#CATEGORY_LAUNCHER CATEGORY_LAUNCHER}. This does not have
{@link Intent#FLAG_ACTIVITY_NEW_TASK FLAG_ACTIVITY_NEW_TASK} set,
though typically you will want to do that through {@link Intent#addFlags(int) addFlags(int)}
on the returned Intent.
return IMPL.makeMainActivity(mainActivity);
|
public static android.content.Intent | makeMainSelectorActivity(java.lang.String selectorAction, java.lang.String selectorCategory)Make an Intent for the main activity of an application, without
specifying a specific activity to run but giving a selector to find
the activity. This results in a final Intent that is structured
the same as when the application is launched from
Home. For anything else that wants to launch an application in the
same way, it is important that they use an Intent structured the same
way, and can use this function to ensure this is the case.
The returned Intent has {@link Intent#ACTION_MAIN} as its action, and includes the
category {@link Intent#CATEGORY_LAUNCHER}. This does not have
{@link Intent#FLAG_ACTIVITY_NEW_TASK} set, though typically you will want
to do that through {@link Intent#addFlags(int)} on the returned Intent.
return IMPL.makeMainSelectorActivity(selectorAction, selectorCategory);
|
public static android.content.Intent | makeRestartActivityTask(android.content.ComponentName mainActivity)Make an Intent that can be used to re-launch an application's task
in its base state. This is like {@link #makeMainActivity(ComponentName)},
but also sets the flags {@link Intent#FLAG_ACTIVITY_NEW_TASK} and
{@link IntentCompat#FLAG_ACTIVITY_CLEAR_TASK}.
return IMPL.makeRestartActivityTask(mainActivity);
|