ContextMenuItem

One item of a #WebKitContextMenu.

The #WebKitContextMenu is composed of #WebKitContextMenuItem<!-- -->s. These items can be created from a #GtkAction, from a #WebKitContextMenuAction or from a #WebKitContextMenuAction and a label. These #WebKitContextMenuAction<!-- -->s denote stock actions for the items. You can also create separators and submenus.

Constructors

this
this(void* ptr, Flag!"Take" take)

Members

Functions

getGaction
gio.action.Action getGaction()

Gets the action associated to item as a #GAction.

getStockAction
webkitwebprocessextension.types.ContextMenuAction getStockAction()

Gets the #WebKitContextMenuAction of item.

getSubmenu
webkitwebprocessextension.context_menu.ContextMenu getSubmenu()

Gets the submenu of item.

isSeparator
bool isSeparator()

Checks whether item is a separator.

self
ContextMenuItem self()

Returns this, for use in with statements.

setSubmenu
void setSubmenu(webkitwebprocessextension.context_menu.ContextMenu submenu)

Sets or replaces the item submenu.

Properties

gType
GType gType [@property getter]

Static functions

getGType
GType getGType()
newFromGaction
webkitwebprocessextension.context_menu_item.ContextMenuItem newFromGaction(gio.action.Action action, string label, glib.variant.VariantG target)

Creates a new #WebKitContextMenuItem for the given action and label.

newFromStockAction
webkitwebprocessextension.context_menu_item.ContextMenuItem newFromStockAction(webkitwebprocessextension.types.ContextMenuAction action)

Creates a new #WebKitContextMenuItem for the given stock action.

newFromStockActionWithLabel
webkitwebprocessextension.context_menu_item.ContextMenuItem newFromStockActionWithLabel(webkitwebprocessextension.types.ContextMenuAction action, string label)

Creates a new #WebKitContextMenuItem for the given stock action using the given label.

newSeparator
webkitwebprocessextension.context_menu_item.ContextMenuItem newSeparator()

Creates a new #WebKitContextMenuItem representing a separator.

newWithSubmenu
webkitwebprocessextension.context_menu_item.ContextMenuItem newWithSubmenu(string label, webkitwebprocessextension.context_menu.ContextMenu submenu)

Creates a new #WebKitContextMenuItem using the given label with a submenu.

Inherited Members

From InitiallyUnowned

getGType
GType getGType()
gType
GType gType [@property getter]
self
InitiallyUnowned self()

Returns this, for use in with statements.