WidgetEventController constructor
WidgetEventController([
- Set<
WidgetEvent> ? events, - ValueSetter<
Set< ? onChangedWidgetEvent> >
Creates a new instance of WidgetEventController.
Optionally allows setting the initial state of the events.
- value: The initial set of active WidgetEvents. Defaults to an empty set.
- onChanged: A callback that will be invoked whenever the set of active events changes.
Implementation
WidgetEventController([
Set<WidgetEvent>? events,
this.onChanged,
]) : value = events ?? {};