reset method
reset field
- clear validation
- set value to initialValue
Implementation
@override
void reset() {
_debounce?.cancel();
_oldTextValue = null;
_options = [];
super.reset();
_stateNotifier.value = null;
if (hasFocusNode) {
focusNode.unfocus();
}
// we do not want to perform a search
effectiveController.removeListener(_fieldChange);
if (value != null) {
effectiveController.text = widget.displayStringForOption(value!);
} else {
effectiveController.text = '';
}
effectiveController.addListener(_fieldChange);
}