rotateWithCrossAxis method
Rotates this offset with crossAxis
where dx
becomes the cross axis
extent and dy
becomes the main axis extent.
Implementation
Offset rotateWithCrossAxis(Axis crossAxis) {
return crossAxis == Axis.horizontal ? this : Offset(dy, dx);
}