AnimatedPositioned constructor

const AnimatedPositioned(
  1. {Key key,
  2. @required Widget child,
  3. double left,
  4. double top,
  5. double right,
  6. double bottom,
  7. double width,
  8. double height,
  9. Curve curve: Curves.linear,
  10. @required Duration duration,
  11. VoidCallback onEnd}

Creates a widget that animates its position implicitly.

Only two out of the three horizontal values (left, right, width), and only two out of the three vertical values (top, bottom, height), can be set. In each case, at least one of the three must be null.

The curve and duration arguments must not be null.


const AnimatedPositioned({
  Key key,
  @required this.child,
  Curve curve = Curves.linear,
  @required Duration duration,
  VoidCallback onEnd,
}) : assert(left == null || right == null || width == null),
     assert(top == null || bottom == null || height == null),
     super(key: key, curve: curve, duration: duration, onEnd: onEnd);