createBallisticSimulation method
Implementation
@override
Simulation? createBallisticSimulation(
ScrollMetrics position, double velocity) {
final mVelocity =
hasSecondary && !noMoreLocked && _offset >= actualSecondaryTriggerOffset
? -secondaryVelocity
: velocity;
if (_offset > 0) {
return BouncingScrollSimulation(
spring: spring,
position:
clamping ? position.minScrollExtent - _offset : position.pixels,
velocity: mVelocity,
leadingExtent: position.minScrollExtent - overExtent,
trailingExtent: 0,
tolerance: _physics.toleranceFor(position),
);
}
return null;
}