ScaleAnimatedWidget.tween constructor
ScaleAnimatedWidget.tween({})
An scale animation using 2 values : enabled - disabled
duration : the duration of the animation, including intermediate values delay : the delay before the animation starts enabled : determine if the animation is stopped or fired curve : An easing curve, see Curve
scaleDisabled : the default value of the widget scaleEnabled : the animated value of the widget
animationFinished : a callback called when the animation is finished
Implementation
ScaleAnimatedWidget.tween({
Duration duration = const Duration(milliseconds: 500),
double scaleEnabled = 1,
double scaleDisabled = 0,
bool enabled = true,
Function(bool)? animationFinished,
Curve curve = Curves.linear,
required Widget child,
}) : this(
duration: duration,
enabled: enabled,
curve: curve,
child: child,
animationFinished: animationFinished,
values: [scaleDisabled, scaleEnabled]);