map: fixed blank google map on app resume
This commit is contained in:
parent
42425f6fcf
commit
7e3288217e
1 changed files with 2 additions and 0 deletions
|
@ -62,6 +62,7 @@ class _EntryGoogleMapState extends State<EntryGoogleMap> with WidgetsBindingObse
|
|||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
WidgetsBinding.instance!.addObserver(this);
|
||||
_registerWidget(widget);
|
||||
}
|
||||
|
||||
|
@ -76,6 +77,7 @@ class _EntryGoogleMapState extends State<EntryGoogleMap> with WidgetsBindingObse
|
|||
void dispose() {
|
||||
_unregisterWidget(widget);
|
||||
_googleMapController?.dispose();
|
||||
WidgetsBinding.instance!.removeObserver(this);
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue