onDragStart property

GestureDragStartCallback? onDragStart
final

Called when the tap event has moved beyond a threshold indicating that the user is dragging.

This will only be called once per drag gesture independent of how many touches are going on until the last touch is complete. onDragUpdate is called as touches move updating the scale as determined by the first two points. onDragEnd is called when the last touch event lifts and the velocity is calculated from the final movement.

onDragStart, onDragUpdate, and onDragEnd are also called for mouse wheel with the scale and point updated given the WheelEvent (deltaY updates the scale, deltaX updates the event point/pans).

TODO: Add a "discrete" flag that tells drag listeners whether they should be expecting a series of continuous updates, or one large update. This will mostly be used to control whether we animate the chart between onDragUpdate calls.

TODO: Investigate low performance of chart rendering from flutter when animation is enabled and we pinch to zoom on the chart.

Implementation

final GestureDragStartCallback? onDragStart;