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.maxScrollExtent + _offset : position.pixels,
velocity: mVelocity,
leadingExtent: 0,
trailingExtent: position.maxScrollExtent + overExtent,
tolerance: _physics.toleranceFor(position),
);
}
return null;
}