SlideAnimation constructor

const SlideAnimation(
  1. {Key key,
  2. Duration duration,
  3. Duration delay,
  4. double verticalOffset,
  5. double horizontalOffset = 0.0,
  6. @required Widget child}
)

Creates a slide animation that slides its child from the given verticalOffset and horizontalOffset to its final position.

A default value of 50.0 is applied to verticalOffset if verticalOffset and horizontalOffset are both undefined or null.

The child argument must not be null.

Implementation

const SlideAnimation({
  Key key,
  this.duration,
  this.delay,
  double verticalOffset,
  this.horizontalOffset = 0.0,
  @required this.child,
})  : verticalOffset = (verticalOffset == null && horizontalOffset == null)
          ? 50.0
          : (verticalOffset ?? 0.0),
      assert(child != null),
      super(key: key);