PMonthPicker constructor

PMonthPicker({
  1. Key? key,
  2. required Jalali selectedDate,
  3. required ValueChanged<Jalali> onChanged,
  4. required Jalali firstDate,
  5. required Jalali lastDate,
  6. PSelectableDayPredicate? selectableDayPredicate,
  7. DragStartBehavior dragStartBehavior = DragStartBehavior.start,
})

Creates a month picker.

Rarely used directly. Instead, typically used as part of the dialog shown by showDatePicker.

Implementation

PMonthPicker({
  Key? key,
  required this.selectedDate,
  required this.onChanged,
  required this.firstDate,
  required this.lastDate,
  this.selectableDayPredicate,
  this.dragStartBehavior = DragStartBehavior.start,
})  : assert(!firstDate.isAfter(lastDate)),
      assert(selectedDate.isAfter(firstDate) ||
          selectedDate.isAtSameMomentAs(firstDate)),
      super(key: key);