updateDragT function
Logoheadless

updateDragT#

double updateDragT({ required double currentT, required double deltaX, required double travelPx, required bool isRtl, });

Updates the drag position based on horizontal drag delta.

currentT is the current 0..1 thumb position. deltaX is the horizontal drag delta in pixels. travelPx is the total travel distance in pixels (trackInnerLength). isRtl indicates right-to-left layout direction.

Returns the new 0..1 thumb position, clamped to 0, 1.