|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectandroid.support.v4.app.ActivityOptionsCompat
public class ActivityOptionsCompat

Helper for accessing features in ActivityOptions
introduced in API level 16 in a backwards compatible fashion.
| Constructor Summary | |
|---|---|
protected |
ActivityOptionsCompat()
|
| Method Summary | |
|---|---|
static ActivityOptionsCompat |
makeCustomAnimation(android.content.Context context,
int enterResId,
int exitResId)
Create an ActivityOptions specifying a custom animation to run when the activity is displayed. |
static ActivityOptionsCompat |
makeScaleUpAnimation(android.view.View source,
int startX,
int startY,
int startWidth,
int startHeight)
Create an ActivityOptions specifying an animation where the new activity is scaled from a small originating area of the screen to its final full representation. |
static ActivityOptionsCompat |
makeThumbnailScaleUpAnimation(android.view.View source,
android.graphics.Bitmap thumbnail,
int startX,
int startY)
Create an ActivityOptions specifying an animation where a thumbnail is scaled from a given position to the new activity window that is being started. |
android.os.Bundle |
toBundle()
Returns the created options as a Bundle, which can be passed to ActivityCompat.startActivity(android.app.Activity, android.content.Intent, android.os.Bundle). |
void |
update(ActivityOptionsCompat otherOptions)
Update the current values in this ActivityOptions from those supplied in otherOptions. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected ActivityOptionsCompat()
| Method Detail |
|---|
public static ActivityOptionsCompat makeCustomAnimation(android.content.Context context,
int enterResId,
int exitResId)
context - Who is defining this. This is the application that the
animation resources will be loaded from.enterResId - A resource ID of the animation resource to use for the
incoming activity. Use 0 for no animation.exitResId - A resource ID of the animation resource to use for the
outgoing activity. Use 0 for no animation.
public static ActivityOptionsCompat makeScaleUpAnimation(android.view.View source,
int startX,
int startY,
int startWidth,
int startHeight)
Intent.setSourceBounds(android.graphics.Rect),
those bounds will be filled in for you based on the initial bounds passed
in here.
source - The View that the new activity is animating from. This
defines the coordinate space for startX and startY.startX - The x starting location of the new activity, relative to
source.startY - The y starting location of the activity, relative to source.startWidth - The initial width of the new activity.startHeight - The initial height of the new activity.
public static ActivityOptionsCompat makeThumbnailScaleUpAnimation(android.view.View source,
android.graphics.Bitmap thumbnail,
int startX,
int startY)
Intent.setSourceBounds(android.graphics.Rect),
those bounds will be filled in for you based on the initial thumbnail
location and size provided here.
source - The View that this thumbnail is animating from. This
defines the coordinate space for startX and startY.thumbnail - The bitmap that will be shown as the initial thumbnail
of the animation.startX - The x starting location of the bitmap, relative to source.startY - The y starting location of the bitmap, relative to source.
public android.os.Bundle toBundle()
ActivityCompat.startActivity(android.app.Activity, android.content.Intent, android.os.Bundle).
Note that the returned Bundle is still owned by the ActivityOptions
object; you must not modify it, but can supply it to the startActivity
methods that take an options Bundle.
public void update(ActivityOptionsCompat otherOptions)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||