animateToDate method
void
animateToDate(
- DateTime date, {
- dynamic duration = const Duration(milliseconds: 500),
- dynamic curve = Curves.linear,
This function will animate to any date that is passed as an argument In case a date is out of range nothing will happen
Implementation
void animateToDate(DateTime date,
{duration = const Duration(milliseconds: 500), curve = Curves.linear}) {
assert(_datePickerState != null,
'DatePickerController is not attached to any DatePicker View.');
_datePickerState!._controller.animateTo(_calculateDateOffset(date),
duration: duration, curve: curve);
}