gi-webkit-6.0.2: WebKit bindings
CopyrightWill Thompson and Iñaki García Etxebarria
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria
Safe HaskellSafe-Inferred
LanguageHaskell2010

GI.WebKit.Objects.AutomationSession

Description

Automation Session.

WebKitAutomationSession represents an automation session of a WebKitWebContext. When a new session is requested, a WebKitAutomationSession is created and the signal WebKitWebContextautomationStarted is emitted with the WebKitAutomationSession as argument. Then, the automation client can request the session to create a new WebView to interact with it. When this happens the signal AutomationSession::createWebView is emitted.

Since: 2.18

Synopsis

Exported types

newtype AutomationSession Source #

Memory-managed wrapper type.

Constructors

AutomationSession (ManagedPtr AutomationSession) 

Instances

Instances details
Eq AutomationSession Source # 
Instance details

Defined in GI.WebKit.Objects.AutomationSession

GObject AutomationSession Source # 
Instance details

Defined in GI.WebKit.Objects.AutomationSession

ManagedPtrNewtype AutomationSession Source # 
Instance details

Defined in GI.WebKit.Objects.AutomationSession

TypedObject AutomationSession Source # 
Instance details

Defined in GI.WebKit.Objects.AutomationSession

Methods

glibType :: IO GType

HasParentTypes AutomationSession Source # 
Instance details

Defined in GI.WebKit.Objects.AutomationSession

IsGValue (Maybe AutomationSession) Source #

Convert AutomationSession to and from GValue. See toGValue and fromGValue.

Instance details

Defined in GI.WebKit.Objects.AutomationSession

Methods

gvalueGType_ :: IO GType

gvalueSet_ :: Ptr GValue -> Maybe AutomationSession -> IO ()

gvalueGet_ :: Ptr GValue -> IO (Maybe AutomationSession)

type ParentTypes AutomationSession Source # 
Instance details

Defined in GI.WebKit.Objects.AutomationSession

type ParentTypes AutomationSession = '[Object]

class (GObject o, IsDescendantOf AutomationSession o) => IsAutomationSession o Source #

Type class for types which can be safely cast to AutomationSession, for instance with toAutomationSession.

Instances

Instances details
(GObject o, IsDescendantOf AutomationSession o) => IsAutomationSession o Source # 
Instance details

Defined in GI.WebKit.Objects.AutomationSession

toAutomationSession :: (MonadIO m, IsAutomationSession o) => o -> m AutomationSession Source #

Cast to AutomationSession, for types for which this is known to be safe. For general casts, use castTo.

Methods

getApplicationInfo

automationSessionGetApplicationInfo Source #

Arguments

:: (HasCallStack, MonadIO m, IsAutomationSession a) 
=> a

session: a AutomationSession

-> m ApplicationInfo

Returns: the AutomationSession of session, or Nothing if no one has been set.

Get the the previously set AutomationSession.

Get the AutomationSession previously set with automationSessionSetApplicationInfo.

Since: 2.18

getId

automationSessionGetId Source #

Arguments

:: (HasCallStack, MonadIO m, IsAutomationSession a) 
=> a

session: a AutomationSession

-> m Text

Returns: the unique identifier of session

Get the unique identifier of a AutomationSession

Since: 2.18

setApplicationInfo

automationSessionSetApplicationInfo Source #

Arguments

:: (HasCallStack, MonadIO m, IsAutomationSession a) 
=> a

session: a AutomationSession

-> ApplicationInfo

info: a ApplicationInfo

-> m () 

Set the application information to session.

This information will be used by the driver service to match the requested capabilities with the actual application information. If this information is not provided to the session when a new automation session is requested, the creation might fail if the client requested a specific browser name or version. This will not have any effect when called after the automation session has been fully created, so this must be called in the callback of WebContext::automationStarted signal.

Since: 2.18

Properties

id

The session unique identifier.

Since: 2.18

constructAutomationSessionId :: (IsAutomationSession o, MonadIO m) => Text -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “id” property. This is rarely needed directly, but it is used by new.

getAutomationSessionId :: (MonadIO m, IsAutomationSession o) => o -> m Text Source #

Get the value of the “id” property. When overloading is enabled, this is equivalent to

get automationSession #id

Signals

createWebView

type AutomationSessionCreateWebViewCallback Source #

Arguments

 = IO WebView

Returns: a WebView widget.

This signal is emitted when the automation client requests a new browsing context to interact with it. The callback handler should return a WebView created with WebView:isControlledByAutomation construct property enabled and WebView:automationPresentationType construct property set if needed.

If the signal is emitted with "tab" detail, the returned WebView should be a new web view added to a new tab of the current browsing context window. If the signal is emitted with "window" detail, the returned WebView should be a new web view added to a new window. When creating a new web view and there's an active browsing context, the new window or tab shouldn't be focused.

Since: 2.18

afterAutomationSessionCreateWebView :: (IsAutomationSession a, MonadIO m) => a -> Maybe Text -> ((?self :: a) => AutomationSessionCreateWebViewCallback) -> m SignalHandlerId Source #

Connect a signal handler for the createWebView signal, to be run after the default handler. When overloading is enabled, this is equivalent to

after automationSession #createWebView callback

This signal admits a optional parameter detail. If it's not Nothing, we will connect to “create-web-view::detail” instead.

By default the object invoking the signal is not passed to the callback. If you need to access it, you can use the implit ?self parameter. Note that this requires activating the ImplicitParams GHC extension.

onAutomationSessionCreateWebView :: (IsAutomationSession a, MonadIO m) => a -> Maybe Text -> ((?self :: a) => AutomationSessionCreateWebViewCallback) -> m SignalHandlerId Source #

Connect a signal handler for the createWebView signal, to be run before the default handler. When overloading is enabled, this is equivalent to

on automationSession #createWebView callback

This signal admits a optional parameter detail. If it's not Nothing, we will connect to “create-web-view::detail” instead.