Closed skyloovportal closed 2 years ago
Hi, @skyloovportal
Callback onPanoramaChangeListener can solve it.
onPanoramaChangeListener callback function is
void Function(StreetViewPanoramaLocation? location, Exception? e){}
and the Exception? e
will not be null while the street view invalid.
Try the code shown below.
const LatLng INVALID = LatLng(-45.125783, 151.276417);
FlutterGoogleStreetView(
initPos: INVALID,
onPanoramaChangeListener: (location, e) {
print("location:$location, e:$e");
},
);
//log
location:null, e:Exception: Oops..., no valid panorama found with position:-45.125783, 151.27641700000004, try to change position
, radius
or source
.
Close this issue here.
The callback onPanoramaChangeListener
will receive exception while the street view invalid.
See demo Street View Panorama events(demo/street_view_panorama_events.dart)
in example
for usage.
Hey, I really appreciate your efforts but i would like to request for an update i.e If there is no street view available for a specific location please provide a callback in platform view in order to show a valid response to the user.
Thanks