CarouselSnapResolver class abstract final

Resolves the target index from horizontal swipe velocity and displacement.

Used by the gesture layer and controller for deterministic index tracking independent of scroll position.

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

resolve({required int currentIndex, required double velocity, required double displacement, required double cardWidth, required int itemCount, double velocityThreshold = 600.0, double distanceThreshold = 0.3}) int
Resolves which index to snap to after a horizontal gesture.