Skip to main content

request_permission_to_use_async

Function request_permission_to_use_async 

Source
pub(crate) fn request_permission_to_use_async(
    name: PermissionName,
    global_scope: &GlobalScope,
    callback: GenericCallback<AllowOrDeny>,
) -> AsyncPermissionRequest
Expand description

Non-blocking variant of request_permission_to_use(), for specifications that obtain permission “in parallel” rather than on the script thread.

callback is only invoked when the return value is AsyncPermissionRequest::Prompting