curvedAnimation property

Animation<double> curvedAnimation

Get default animation with Tween<double>(begin:0.0, end:1.0) and with the defined curve, Used with Flutter's widgets that end with Transition (ex SlideTransition, RotationTransition)

Implementation

Animation<double> get curvedAnimation {
  assert(_controller != null);
  final hasReverseCurve = (this as InjectedAnimationImp).reverseCurve != null;
  if (!hasReverseCurve) {
    return _curvedAnimation ??= CurvedAnimation(
      parent: _controller!,
      curve: (this as InjectedAnimationImp).curve,
    );
  }
  return _reverseCurvedAnimation ??= CurvedAnimation(
    parent: _controller!,
    curve: _controller!.status == AnimationStatus.reverse
        ? (this as InjectedAnimationImp).reverseCurve!
        : (this as InjectedAnimationImp).curve,
  );
}