onGeolocationPermissionsShowPrompt method
FutureOr<GeolocationPermissionShowPromptResponse?> ?
onGeolocationPermissionsShowPrompt(
- String origin
inherited
Event that notifies the host application that web content from the specified origin is attempting to use the Geolocation API, but no permission state is currently set for that origin.
Note that for applications targeting Android N and later SDKs (API level > Build.VERSION_CODES.M) this method is only called for requests originating from secure origins such as https.
On non-secure origins geolocation requests are automatically denied.
origin represents the origin of the web content attempting to use the Geolocation API.
Officially Supported Platforms/Implementations:
- Android WebView (Official API - WebChromeClient.onGeolocationPermissionsShowPrompt)
Parameters - Officially Supported Platforms/Implementations:
origin: all platforms
Use the PlatformInAppBrowserEvents.isMethodSupported method to check if this method is supported at runtime.
Implementation
@override
FutureOr<GeolocationPermissionShowPromptResponse?>?
onGeolocationPermissionsShowPrompt(String origin) {
return null;
}