refresh method
void
refresh()
Rebuild the 'latest/current' State object and the 'root/first' State object This is to address the possibility an App has called another App.
Implementation
void refresh() {
_AppState? _state;
if (_AppState._appInApp) {
_state = lastContext?.findAncestorStateOfType<_AppState>();
}
if (_state == null) {
lastState?.setState(() {});
// Refresh the 'root' State object.
super.setState(() {});
} else {
_state.setState(() {});
}
}