alignAxis function

Offset alignAxis(
  1. Offset offset,
  2. Axis axis
)

Implementation

Offset alignAxis(Offset offset, Axis axis) {
  switch (axis) {
    case Axis.horizontal:
      return Offset(offset.dx, 0.0);
    case Axis.vertical:
      return Offset(0.0, offset.dy);
  }
}