setState method
- @protected
- void fn()
Runs fn, which changes this state, and rebuilds the element in the
owner's next build scope.
Implementation
@protected
void setState(void Function() fn) {
assert(_element != null, 'setState() called after dispose(): $this');
fn();
_element!.markNeedsBuild();
}