clear method
dynamic
clear()
Implementation
clear() {
if (_state == ToastedState.none) {
return;
}
_timer!.cancel();
_timer = null;
_state = ToastedState.none;
_onEvent();
// Clear the queue last so that if there is a current toast displayed
// when the queue is cleared, it will be passed along in the onEvent handler.
_queue.clear();
}