stopDrag method

  1. @override
void stopDrag()
override

Ends the startDrag method.

A sprite that was made draggable with the startDrag method remains draggable until a stopDrag method is added or the sprite was dragged with a different touch point.

Implementation

@override
void stopDrag() {
  final stage = this.stage;
  stage?._stopDrag(this);
}