FormeFluentTimePicker constructor

FormeFluentTimePicker({
  1. Key? key,
  2. String? name,
  3. DateTime? initialValue,
  4. FormeAsyncValidator<DateTime?>? asyncValidator,
  5. Duration? asyncValidatorDebounce,
  6. AutovalidateMode? autovalidateMode,
  7. FormeFieldDecorator<DateTime?>? decorator,
  8. bool enabled = true,
  9. FocusNode? focusNode,
  10. FormeFieldInitialized<DateTime?>? onInitialized,
  11. FormeFieldSetter<DateTime?>? onSaved,
  12. FormeFieldStatusChanged<DateTime?>? onStatusChanged,
  13. int? order,
  14. bool quietlyValidate = false,
  15. bool readOnly = false,
  16. bool requestFocusOnUserInteraction = true,
  17. FormeFieldValidationFilter<DateTime?>? validationFilter,
  18. FormeValidator<DateTime?>? validator,
  19. bool autofocus = false,
  20. EdgeInsetsGeometry contentPadding = kPickerContentPadding,
  21. String? header,
  22. TextStyle? headerStyle,
  23. HourFormat hourFormat = HourFormat.h,
  24. int minuteIncrement = 1,
  25. VoidCallback? onCancel,
  26. double popupHeight = kPickerPopupHeight,
})

Implementation

FormeFluentTimePicker({
  super.key,
  super.name,
  super.initialValue,
  super.asyncValidator,
  super.asyncValidatorDebounce,
  super.autovalidateMode,
  super.decorator,
  super.enabled = true,
  super.focusNode,
  super.onInitialized,
  super.onSaved,
  super.onStatusChanged,
  super.order,
  super.quietlyValidate = false,
  super.readOnly = false,
  super.requestFocusOnUserInteraction = true,
  super.validationFilter,
  super.validator,
  this.autofocus = false,
  this.contentPadding = kPickerContentPadding,
  this.header,
  this.headerStyle,
  this.hourFormat = HourFormat.h,
  this.minuteIncrement = 1,
  this.onCancel,
  this.popupHeight = kPickerPopupHeight,
}) : super.allFields(
        builder: (state) {
          return TimePicker(
            onCancel: onCancel,
            hourFormat: hourFormat,
            header: header,
            headerStyle: headerStyle,
            contentPadding: contentPadding,
            popupHeight: popupHeight,
            focusNode: state.focusNode,
            autofocus: autofocus,
            minuteIncrement: minuteIncrement,
            selected: state.value,
            onChanged: readOnly
                ? null
                : (value) {
                    state.didChange(value);
                    state.requestFocusOnUserInteraction();
                  },
          );
        },
      );