transitionBuilder property

AnimatedSwitcherTransitionBuilder transitionBuilder
final

A function that wraps a new child with an animation that transitions the child in when the animation runs in the forward direction and out when the animation runs in the reverse direction. This is only called when a new child is set (not for each build), or when a new transitionBuilder is set. If a new transitionBuilder is set, then the transition is rebuilt for the current child and all previous children using the new transitionBuilder. The function must not return null.

The default is AnimatedSwitcher.defaultTransitionBuilder.

The animation provided to the builder has the duration and switchInCurve or switchOutCurve applied as provided when the corresponding child was first provided.

See also:

Implementation

final AnimatedSwitcherTransitionBuilder transitionBuilder