What is the “touch slop” ?
I’ve encountered this term in
docstring but I can’t make sense of what it means.
06/23/2022, 1:25 PM
Amount of distance a motion event has to travel before being considering a drag/fling rather than a touch/click.
06/23/2022, 1:28 PM
Ohhhh, so some sort of threshold between “static” motion events (tap) and other non-static motion events (drag, pinch, rotate) ?
06/23/2022, 1:30 PM
yes. we are imprecise meat bags with fat fingers and shaky wrists so this value ensures you've done significant movement before honoring it.
06/23/2022, 2:37 PM
Also when there are multiple gesture detectors, e.g. a vertical scrollable list in a horizontal scrollable pager, they will start capturing pointer input after the pointer moves past touch slop in that axis and this allows the parent to detect the gesture. Otherwise the child will immediately start capturing, leaving no chance to the parent.