fromTween<T> method

T? fromTween<T>(
  1. Tween<T?> fn(
    1. T? currentValue
    ), [
  2. String? name
])

Set animation explicitly by defining the Tween.

The callback exposes the currentValue value

Implementation

T? fromTween<T>(Tween<T?> Function(T? currentValue) fn, [String? name]) {
  final curve = _curve;
  final reserveCurve = _reserveCurve;
  _curve = null;
  _reserveCurve = null;
  return _fromTween(fn, curve, reserveCurve, name ?? '');
}