public class NavigationalTransitionCompat extends BaseNavigationalTransition<NavigationalTransitionCompat>
BaseNavigationalTransition implementation that may be used also from a context of
support Fragment.
See start(Fragment) and finish(Fragment) for more information.
MATERIAL_SUPPORT, mClassOfTransitionActivity, RC_NONE| Constructor and Description |
|---|
NavigationalTransitionCompat()
Creates a new instance of NavigationalTransitionCompat without transition activity.
|
NavigationalTransitionCompat(Class<? extends Activity> classOfTransitionActivity)
Creates a new instance of NavigationalTransitionCompat with the specified classOfTransitionActivity.
|
| Modifier and Type | Method and Description |
|---|---|
void |
finish(Fragment caller)
Finishes host activity of the given caller fragment in order to run its exit transitions.
|
protected void |
onFinish(Fragment caller)
Invoked whenever
finish(Fragment) is called. |
protected void |
onStart(Fragment caller)
Invoked whenever
start(Fragment) is called. |
void |
start(Fragment caller)
Starts this navigational transition using the given caller fragment with transitions
and shared elements that are configured for the caller's parent activity via
BaseNavigationalTransition.configureOutgoingTransitions(Activity). |
allowEnterTransitionOverlap, allowEnterTransitionOverlap, allowReturnTransitionOverlap, allowReturnTransitionOverlap, configureIncomingTransitions, configureOutgoingTransitions, configureTransitions, createIntent, enterTransition, enterTransition, exitTransition, exitTransition, finish, finishCaller, finishCallerDelayed, getActivityClass, inflateTransition, inflateTransitionManager, intentExtras, intentExtras, makeSceneTransitionAnimation, onFinish, onFinishCaller, onStart, reenterTransition, reenterTransition, requestCode, requestCode, returnTransition, returnTransition, sharedElement, sharedElementEnterTransition, sharedElementEnterTransition, sharedElementExitTransition, sharedElementExitTransition, sharedElementReenterTransition, sharedElementReenterTransition, sharedElementReturnTransition, sharedElementReturnTransition, sharedElements, sharedElements, sharedElementsUseOverlay, sharedElementsUseOverlay, singleSharedElement, startpublic NavigationalTransitionCompat()
public NavigationalTransitionCompat(@NonNull Class<? extends Activity> classOfTransitionActivity)
classOfTransitionActivity - The activity class that will be used to create an Intent
whenever starting this transition.BaseNavigationalTransition.createIntent(Activity)public void start(@NonNull Fragment caller)
BaseNavigationalTransition.configureOutgoingTransitions(Activity).
Note that unlike BaseNavigationalTransition.start(Activity) this cannot be used to start new activity
with shared elements presented. For that purpose use BaseNavigationalTransition.start(Activity) instead.
caller - The fragment that will be used to create and start an Intent created via
BaseNavigationalTransition.createIntent(Activity).BaseNavigationalTransition.configureTransitions(Activity)protected void onStart(@NonNull Fragment caller)
start(Fragment) is called.
Default implementation starts an Intent created via BaseNavigationalTransition.createIntent(Activity) using
the given caller fragment via Fragment.startActivity(Intent) if there was no
BaseNavigationalTransition.requestCode() specified and via Fragment.startActivityForResult(Intent, int)
if there was.
caller - The caller fragment that requested start of this navigational transition.onFinish(Fragment)public void finish(@NonNull Fragment caller)
caller - The fragment of which activity should be finished and of which exit transitions
should be started.start(Fragment)protected void onFinish(@NonNull Fragment caller)
finish(Fragment) is called.
Default implementation invokes BaseNavigationalTransition.onFinish(Activity) with a host activity of the given
caller fragment.
caller - The fragment that requested finish of its host activity via this navigational transition.onStart(Fragment)