startAnnotationDrag method

void startAnnotationDrag(
  1. String annotationId
)

Starts an annotation drag operation.

Call this from AnnotationWidget's GestureDetector.onPanStart.

Parameters:

  • annotationId: The ID of the annotation being dragged

Implementation

void startAnnotationDrag(String annotationId) {
  // Disable panning during annotation drag so InteractiveViewer
  // doesn't steal the gesture from AnnotationWidget's GestureDetector
  runInAction(() {
    interaction.panEnabled.value = false;
  });
  annotations.internalStartAnnotationDrag(annotationId);
}