public abstract class SharedElementTransitionChangeHandler extends TransitionChangeHandler
TransitionChangeHandler.OnTransitionPreparedListener| Constructor and Description |
|---|
SharedElementTransitionChangeHandler() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addSharedElement(java.lang.String name)
Used to register an element that will take part in the shared element transition.
|
protected void |
addSharedElement(java.lang.String fromName,
java.lang.String toName)
Used to register an element that will take part in the shared element transition.
|
protected void |
addSharedElement(android.view.View sharedElement,
java.lang.String toName)
Used to register an element that will take part in the shared element transition.
|
boolean |
allowTransitionOverlap(boolean isPush)
Should return whether or not the the exit transition and enter transition should overlap.
|
abstract void |
configureSharedElements(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
boolean isPush)
Will be called when views are ready to have their shared elements configured.
|
void |
executePropertyChanges(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
Transition transition,
boolean isPush)
This should set all view properties needed for the transition to work properly.
|
abstract Transition |
getEnterTransition(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
boolean isPush)
Should return the transition that will be used on the entering ("to") view, if one is desired.
|
SharedElementCallback |
getEnterTransitionCallback(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
boolean isPush)
Should return a callback that can be used to customize transition behavior of the shared element transition for the "to" view.
|
abstract Transition |
getExitTransition(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
boolean isPush)
Should return the transition that will be used on the exiting ("from") view, if one is desired.
|
SharedElementCallback |
getExitTransitionCallback(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
boolean isPush)
Should return a callback that can be used to customize transition behavior of the shared element transition for the "from" view.
|
abstract Transition |
getSharedElementTransition(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
boolean isPush)
Should return the transition that will be used on shared elements between the from and to views.
|
protected Transition |
getTransition(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
boolean isPush)
Should be overridden to return the Transition to use while replacing Views.
|
void |
onAbortPush(ControllerChangeHandler newHandler,
Controller newTop) |
void |
prepareForTransition(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
Transition transition,
boolean isPush,
TransitionChangeHandler.OnTransitionPreparedListener onTransitionPreparedListener)
Called before a transition occurs.
|
protected void |
waitOnSharedElementNamed(java.lang.String name)
The transition will be delayed until the view with the name passed in is available in the "to" hierarchy.
|
completeImmediately, performChange, removesFromViewOnPushpublic SharedElementTransitionChangeHandler()
protected final Transition getTransition(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
boolean isPush)
TransitionChangeHandlergetTransition in class TransitionChangeHandlercontainer - The container these Views are hosted infrom - The previous View in the container or null if there was no Controller before this transitionto - The next View that should be put in the container or null if no Controller is being transitioned toisPush - True if this is a push transaction, false if it's a poppublic void prepareForTransition(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
Transition transition,
boolean isPush,
TransitionChangeHandler.OnTransitionPreparedListener onTransitionPreparedListener)
TransitionChangeHandleronTransitionPreparedListener is called.prepareForTransition in class TransitionChangeHandlercontainer - The container these Views are hosted infrom - The previous View in the container or null if there was no Controller before this transitionto - The next View that should be put in the container or null if no Controller is being transitioned totransition - The transition that is being prepared forisPush - True if this is a push transaction, false if it's a poppublic final void executePropertyChanges(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
Transition transition,
boolean isPush)
TransitionChangeHandlerexecutePropertyChanges in class TransitionChangeHandlercontainer - The container these Views are hosted infrom - The previous View in the container or null if there was no Controller before this transitionto - The next View that should be put in the container or null if no Controller is being transitioned totransition - The transition with which TransitionManager.beginDelayedTransition has been called. This will be null only if another ControllerChangeHandler immediately overrides this one.isPush - True if this is a push transaction, false if it's a poppublic void onAbortPush(ControllerChangeHandler newHandler,
Controller newTop)
onAbortPush in class TransitionChangeHandlerpublic abstract void configureSharedElements(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
boolean isPush)
public abstract Transition getExitTransition(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
boolean isPush)
public abstract Transition getSharedElementTransition(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
boolean isPush)
public abstract Transition getEnterTransition(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
boolean isPush)
public SharedElementCallback getExitTransitionCallback(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
boolean isPush)
public SharedElementCallback getEnterTransitionCallback(android.view.ViewGroup container,
android.view.View from,
android.view.View to,
boolean isPush)
public boolean allowTransitionOverlap(boolean isPush)
protected final void addSharedElement(java.lang.String name)
name - The transition name that is used for both the entering and exiting views.protected final void addSharedElement(java.lang.String fromName,
java.lang.String toName)
fromName - The transition name used in the "from" viewtoName - The transition name used in the "to" viewprotected final void addSharedElement(android.view.View sharedElement,
java.lang.String toName)
sharedElement - The view from the "from" view that will take part in the shared element transitiontoName - The transition name used in the "to" viewprotected final void waitOnSharedElementNamed(java.lang.String name)