WebKit.PermissionStateQuery

Fields

None

Methods

finish (state)

get_name ()

get_security_origin ()

ref ()

unref ()

Details

class WebKit.PermissionStateQuery

This query represents a user’s choice to allow or deny access to “powerful features” of the platform, as specified in the Permissions W3C Specification.

When signalled by the WebKit.WebView through the query-permission-state signal, the application has to eventually respond, via webkit_permission_state_query_finish(), whether it grants, denies or requests a dedicated permission prompt for the given query.

When a WebKit.PermissionStateQuery is not handled by the user, the user-agent is instructed to prompt the user for the given permission.

finish(state)
Parameters:

state (WebKit.PermissionState) – a WebKit.PermissionState

Notify the web-engine of the selected permission state for the given query. This function should only be called as a response to the WebKitWebView::query-permission-state signal.

New in version 2.40.

get_name()
Returns:

the permission name for self

Return type:

str

Get the permission name for which access is being queried.

New in version 2.40.

get_security_origin()
Returns:

A WebKit.SecurityOrigin representing the origin from which the self was emitted.

Return type:

WebKit.SecurityOrigin

Get the permission origin for which access is being queried.

New in version 2.40.

ref()
Returns:

The passed WebKit.PermissionStateQuery

Return type:

WebKit.PermissionStateQuery

Atomically increments the reference count of self by one.

This function is MT-safe and may be called from any thread.

New in version 2.40.

unref()

Atomically decrements the reference count of self by one.

If the reference count drops to 0, all memory allocated by WebKit.PermissionStateQuery is released. This function is MT-safe and may be called from any thread.

New in version 2.40.