onResizeTL method

dynamic onResizeTL(
  1. DragUpdateDetails details
)

Implementation

onResizeTL(DragUpdateDetails details)
{
  if (widget.model.resizeable == false) return;
  if (((width  ?? 0) - details.delta.dx) < minimumSize) return;
  if (((height ?? 0) + details.delta.dy) < minimumSize) return;

  setState(()
  {
    width  = (width  ?? 0) - details.delta.dx;
    height = (height ?? 0) - details.delta.dy;

    dx = dx! + details.delta.dx;
    dy = dy! + details.delta.dy;

    lastDx     = dx;
    lastDy     = dy;

    lastWidth  = width;
    lastHeight = height;
  });
}