Interface

WebKit-6.0WebKitWebContextSignalSignatures

interface SignalSignatures {
    "automation-started": (arg0: WebKit.AutomationSession) => void;
    "initialize-notification-permissions": () => void;
    "initialize-web-process-extensions": () => void;
    notify: (arg0: GObject.ParamSpec) => void;
    "notify::memory-pressure-settings": (pspec: GObject.ParamSpec) => void;
    "notify::time-zone-override": (pspec: GObject.ParamSpec) => void;
    "user-message-received": (arg0: WebKit.UserMessage) => boolean | void;
}

Hierarchy (View Summary)

Index

Properties

"automation-started": (arg0: WebKit.AutomationSession) => void

This signal is emitted when a new automation request is made. Note that it will never be emitted if automation is not enabled in context, see webkit_web_context_set_automation_allowed() for more details.

2.18

"initialize-notification-permissions": () => void

This signal is emitted when a WebKit.WebContext needs to set initial notification permissions for a web process. It is emitted when a new web process is about to be launched, and signals the most appropriate moment to use webkit_web_context_initialize_notification_permissions(). If no notification permissions have changed since the last time this signal was emitted, then there is no need to call webkit_web_context_initialize_notification_permissions() again.

2.16

"initialize-web-process-extensions": () => void

This signal is emitted when a new web process is about to be launched. It signals the most appropriate moment to use webkit_web_context_set_web_process_extensions_initialization_user_data() and webkit_web_context_set_web_process_extensions_directory().

2.4

"notify::memory-pressure-settings": (pspec: GObject.ParamSpec) => void
"notify::time-zone-override": (pspec: GObject.ParamSpec) => void
"user-message-received": (arg0: WebKit.UserMessage) => boolean | void

This signal is emitted when a WebKit.UserMessage is received from a web process extension. You can reply to the message using webkit_user_message_send_reply().

You can handle the user message asynchronously by calling g_object_ref() on message and returning true.

2.28

Properties - Inherited from GObject

notify: (arg0: GObject.ParamSpec) => void

The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with GObject.ParamFlags.EXPLICIT_NOTIFY, then any call to g_object_set_property() results in ::notify being emitted, even if the new value is the same as the old. If they did pass GObject.ParamFlags.EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

g_signal_connect (text_view->buffer, "notify::paste-target-list",
G_CALLBACK (gtk_text_view_target_list_notify),
text_view)

It is important to note that you must use [canonical parameter names][class@GObject.ParamSpec#parameter-names] as detail strings for the notify signal.