changeMonth method

void changeMonth(
  1. BuildContext context, {
  2. required bool next,
})

Implementation

void changeMonth(BuildContext context, {required bool next}) {
  if (next) {
    CalendarUtils.nextMonth();
  } else {
    CalendarUtils.previousMonth();
  }

  final month =
  CalendarUtils.getPartByInt(format: PartFormat.MONTH);

  onMonthChanged.call(month);
}