LongPressDraggable<T> constructor

const LongPressDraggable<T>({Key key, @required Widget child, @required Widget feedback, T data, Axis axis, Widget childWhenDragging, Offset feedbackOffset: Offset.zero, DragAnchor dragAnchor: DragAnchor.child, int maxSimultaneousDrags, VoidCallback onDragStarted, DraggableCanceledCallback onDraggableCanceled, DragEndCallback onDragEnd, VoidCallback onDragCompleted, bool hapticFeedbackOnStart: true, bool ignoringFeedbackSemantics: true })

Creates a widget that can be dragged starting from long press.

The child and feedback arguments must not be null. If maxSimultaneousDrags is non-null, it must be non-negative.

Implementation

const LongPressDraggable({
  Key key,
  @required Widget child,
  @required Widget feedback,
  T data,
  Axis axis,
  Widget childWhenDragging,
  Offset feedbackOffset = Offset.zero,
  DragAnchor dragAnchor = DragAnchor.child,
  int maxSimultaneousDrags,
  VoidCallback onDragStarted,
  DraggableCanceledCallback onDraggableCanceled,
  DragEndCallback onDragEnd,
  VoidCallback onDragCompleted,
  this.hapticFeedbackOnStart = true,
  bool ignoringFeedbackSemantics = true,
}) : super(
  key: key,
  child: child,
  feedback: feedback,
  data: data,
  axis: axis,
  childWhenDragging: childWhenDragging,
  feedbackOffset: feedbackOffset,
  dragAnchor: dragAnchor,
  maxSimultaneousDrags: maxSimultaneousDrags,
  onDragStarted: onDragStarted,
  onDraggableCanceled: onDraggableCanceled,
  onDragEnd: onDragEnd,
  onDragCompleted: onDragCompleted,
  ignoringFeedbackSemantics: ignoringFeedbackSemantics,
);