gi-webkit-6.0.3: 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.BackForwardList

Description

List of visited pages.

WebKitBackForwardList maintains a list of visited pages used to navigate to recent pages. Items are inserted in the list in the order they are visited.

WebKitBackForwardList also maintains the notion of the current item (which is always at index 0), the preceding item (which is at index -1), and the following item (which is at index 1). Methods webViewGoBack and webViewGoForward move the current item backward or forward by one. Method webViewGoToBackForwardListItem sets the current item to the specified item. All other methods returning BackForwardListItems do not change the value of the current item, they just return the requested item or items.

Synopsis

Exported types

newtype BackForwardList Source #

Memory-managed wrapper type.

Constructors

BackForwardList (ManagedPtr BackForwardList) 

Instances

Instances details
Eq BackForwardList Source # 
Instance details

Defined in GI.WebKit.Objects.BackForwardList

GObject BackForwardList Source # 
Instance details

Defined in GI.WebKit.Objects.BackForwardList

ManagedPtrNewtype BackForwardList Source # 
Instance details

Defined in GI.WebKit.Objects.BackForwardList

TypedObject BackForwardList Source # 
Instance details

Defined in GI.WebKit.Objects.BackForwardList

Methods

glibType :: IO GType

HasParentTypes BackForwardList Source # 
Instance details

Defined in GI.WebKit.Objects.BackForwardList

IsGValue (Maybe BackForwardList) Source #

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

Instance details

Defined in GI.WebKit.Objects.BackForwardList

Methods

gvalueGType_ :: IO GType

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

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

type ParentTypes BackForwardList Source # 
Instance details

Defined in GI.WebKit.Objects.BackForwardList

type ParentTypes BackForwardList = '[Object]

class (GObject o, IsDescendantOf BackForwardList o) => IsBackForwardList o Source #

Type class for types which can be safely cast to BackForwardList, for instance with toBackForwardList.

Instances

Instances details
(GObject o, IsDescendantOf BackForwardList o) => IsBackForwardList o Source # 
Instance details

Defined in GI.WebKit.Objects.BackForwardList

toBackForwardList :: (MonadIO m, IsBackForwardList o) => o -> m BackForwardList Source #

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

Methods

getBackItem

backForwardListGetBackItem Source #

Arguments

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

backForwardList: a BackForwardList

-> m (Maybe BackForwardListItem)

Returns: the BackForwardListItem preceding the current item or Nothing.

Returns the item that precedes the current item.

getBackList

backForwardListGetBackList Source #

Arguments

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

backForwardList: a BackForwardList

-> m [BackForwardListItem]

Returns: a List of items preceding the current item.

Obtain the list of items preceding the current one.

getBackListWithLimit

backForwardListGetBackListWithLimit Source #

Arguments

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

backForwardList: a BackForwardList

-> Word32

limit: the number of items to retrieve

-> m [BackForwardListItem]

Returns: a List of items preceding the current item limited by limit.

Obtain a list up to some number of items preceding the current one.

getCurrentItem

backForwardListGetCurrentItem Source #

Arguments

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

backForwardList: a BackForwardList

-> m (Maybe BackForwardListItem)

Returns: a BackForwardListItem or Nothing if backForwardList is empty.

Returns the current item in backForwardList.

getForwardItem

backForwardListGetForwardItem Source #

Arguments

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

backForwardList: a BackForwardList

-> m (Maybe BackForwardListItem)

Returns: the BackForwardListItem following the current item or Nothing.

Returns the item that follows the current item.

getForwardList

backForwardListGetForwardList Source #

Arguments

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

backForwardList: a BackForwardList

-> m [BackForwardListItem]

Returns: a List of items following the current item.

Obtain the list of items following the current one.

getForwardListWithLimit

backForwardListGetForwardListWithLimit Source #

Arguments

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

backForwardList: a BackForwardList

-> Word32

limit: the number of items to retrieve

-> m [BackForwardListItem]

Returns: a List of items following the current item limited by limit.

Obtain a list up to some number of items following the current one.

getLength

backForwardListGetLength Source #

Arguments

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

backForwardList: a BackForwardList

-> m Word32

Returns: the length of backForwardList.

Obtain the amount of items in the list.

getNthItem

backForwardListGetNthItem Source #

Arguments

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

backForwardList: a BackForwardList

-> Int32

index: the index of the item

-> m (Maybe BackForwardListItem)

Returns: the BackForwardListItem located at the specified index relative to the current item or Nothing.

Returns the item at a given index relative to the current item.

Signals

changed

type BackForwardListChangedCallback Source #

Arguments

 = Maybe BackForwardListItem

itemAdded: the BackForwardListItem added or Nothing

-> Ptr ()

itemsRemoved: a List of BackForwardListItems

-> IO () 

This signal is emitted when backForwardList changes. This happens when the current item is updated, a new item is added or one or more items are removed. Note that both itemAdded and itemsRemoved can Nothing when only the current item is updated. Items are only removed when the list is cleared or the maximum items limit is reached.

afterBackForwardListChanged :: (IsBackForwardList a, MonadIO m) => a -> ((?self :: a) => BackForwardListChangedCallback) -> m SignalHandlerId Source #

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

after backForwardList #changed callback

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.

onBackForwardListChanged :: (IsBackForwardList a, MonadIO m) => a -> ((?self :: a) => BackForwardListChangedCallback) -> m SignalHandlerId Source #

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

on backForwardList #changed callback