animateSnap method
Animates the current value to the nearest integer.
Implementation
void animateSnap(Duration duration, [Curve curve = Curves.easeInOut]) {
_controller.push(
AnimationRequest(_controller.value.roundToDouble(), duration, curve));
}