handlerPointerUp method

  1. @override
bool handlerPointerUp(
  1. PointerUpEvent event
)
override

Implementation

@override
bool handlerPointerUp(PointerUpEvent event) {
  final gEvent = GestureEvent.fromPointerEvent(
    event,
    screenToWorld: gameRef.screenToWorld,
    globalToViewportPosition: gameRef.globalToViewportPosition,
  );
  if (gEvent.pointer == _pointer && _inMoving) {
    _startDragPosition = null;
    _startDragOffset = null;
    _pointer = -1;
    _inMoving = false;
    onEndDrag(gEvent);
  }

  return super.handlerPointerUp(event);
}