getBounds method
Return MFLatLngBounds
defining the region that is visible in a map.
Implementation
Future<MFLatLngBounds?> getBounds() async {
final Map<String, dynamic> latLngBounds =
(await _channel.invokeMapMethod<String, dynamic>('map#getBounds'))!;
final MFLatLng? southwest = MFLatLng.fromJson(latLngBounds['southwest']);
final MFLatLng? northeast = MFLatLng.fromJson(latLngBounds['northeast']);
if (southwest == null || northeast == null) {
return null;
}
return MFLatLngBounds(southwest: southwest, northeast: northeast);
}