i have a problem when using google maps with Flutter,
https://pub.dev/packages/google_maps_flutter
My code is as below:
GoogleMap(
mapType: MapType.normal,
myLocationEnabled: true,
myLocationButtonEnabled: true,
onMapCreated: _onMapCreated,
padding: EdgeInsets.only(top: ScreenUtil().setHeight(100)),
zoomControlsEnabled: false,
initialCameraPosition: CameraPosition(
target: _currentPosition ?? Constants.DEFAULT_POSITION,
zoom: 17,
),
)
At the first time it run, the location permission dialog shown up, And when i accept the permission, the my location button didn't apprear.
At the second time i open the googlemap page (at this time, the permission is already granted), the my location is shown as normal.
Thanks