272 lines
11 KiB
C#
272 lines
11 KiB
C#
// This file was generated by the Gtk# code generator.
|
|
// Any changes made will be lost if regenerated.
|
|
|
|
namespace WebKit {
|
|
|
|
using System;
|
|
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using System.Runtime.InteropServices;
|
|
using static GLib.AbiStructExtension;
|
|
|
|
#region Autogenerated code
|
|
public partial class ContextMenuItem : GLib.InitiallyUnowned {
|
|
|
|
public ContextMenuItem (IntPtr raw) : base(raw) {}
|
|
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
|
delegate IntPtr d_webkit_context_menu_item_new(IntPtr action);
|
|
static d_webkit_context_menu_item_new webkit_context_menu_item_new = FuncLoader.LoadFunction<d_webkit_context_menu_item_new>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Webkit), "webkit_context_menu_item_new"));
|
|
|
|
[Obsolete]
|
|
public ContextMenuItem (Gtk.Action action) : base (IntPtr.Zero)
|
|
{
|
|
if (GetType () != typeof (ContextMenuItem)) {
|
|
var vals = new List<GLib.Value> ();
|
|
var names = new List<string> ();
|
|
CreateNativeObject (names.ToArray (), vals.ToArray ());
|
|
return;
|
|
}
|
|
Raw = webkit_context_menu_item_new(action == null ? IntPtr.Zero : action.Handle);
|
|
}
|
|
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
|
delegate IntPtr d_webkit_context_menu_item_new_from_gaction(IntPtr action, IntPtr label, IntPtr target);
|
|
static d_webkit_context_menu_item_new_from_gaction webkit_context_menu_item_new_from_gaction = FuncLoader.LoadFunction<d_webkit_context_menu_item_new_from_gaction>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Webkit), "webkit_context_menu_item_new_from_gaction"));
|
|
|
|
public ContextMenuItem (GLib.IAction action, string label, GLib.Variant target) : base (IntPtr.Zero)
|
|
{
|
|
if (GetType () != typeof (ContextMenuItem)) {
|
|
var vals = new List<GLib.Value> ();
|
|
var names = new List<string> ();
|
|
CreateNativeObject (names.ToArray (), vals.ToArray ());
|
|
return;
|
|
}
|
|
IntPtr native_label = GLib.Marshaller.StringToPtrGStrdup (label);
|
|
Raw = webkit_context_menu_item_new_from_gaction(action == null ? IntPtr.Zero : ((action is GLib.Object) ? (action as GLib.Object).Handle : (action as GLib.ActionAdapter).Handle), native_label, target == null ? IntPtr.Zero : target.Handle);
|
|
GLib.Marshaller.Free (native_label);
|
|
}
|
|
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
|
delegate IntPtr d_webkit_context_menu_item_new_from_stock_action(int action);
|
|
static d_webkit_context_menu_item_new_from_stock_action webkit_context_menu_item_new_from_stock_action = FuncLoader.LoadFunction<d_webkit_context_menu_item_new_from_stock_action>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Webkit), "webkit_context_menu_item_new_from_stock_action"));
|
|
|
|
public ContextMenuItem (WebKit.ContextMenuAction action) : base (IntPtr.Zero)
|
|
{
|
|
if (GetType () != typeof (ContextMenuItem)) {
|
|
var vals = new List<GLib.Value> ();
|
|
var names = new List<string> ();
|
|
CreateNativeObject (names.ToArray (), vals.ToArray ());
|
|
return;
|
|
}
|
|
Raw = webkit_context_menu_item_new_from_stock_action((int) action);
|
|
}
|
|
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
|
delegate IntPtr d_webkit_context_menu_item_new_from_stock_action_with_label(int action, IntPtr label);
|
|
static d_webkit_context_menu_item_new_from_stock_action_with_label webkit_context_menu_item_new_from_stock_action_with_label = FuncLoader.LoadFunction<d_webkit_context_menu_item_new_from_stock_action_with_label>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Webkit), "webkit_context_menu_item_new_from_stock_action_with_label"));
|
|
|
|
public ContextMenuItem (WebKit.ContextMenuAction action, string label) : base (IntPtr.Zero)
|
|
{
|
|
if (GetType () != typeof (ContextMenuItem)) {
|
|
var vals = new List<GLib.Value> ();
|
|
var names = new List<string> ();
|
|
CreateNativeObject (names.ToArray (), vals.ToArray ());
|
|
return;
|
|
}
|
|
IntPtr native_label = GLib.Marshaller.StringToPtrGStrdup (label);
|
|
Raw = webkit_context_menu_item_new_from_stock_action_with_label((int) action, native_label);
|
|
GLib.Marshaller.Free (native_label);
|
|
}
|
|
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
|
delegate IntPtr d_webkit_context_menu_item_new_separator();
|
|
static d_webkit_context_menu_item_new_separator webkit_context_menu_item_new_separator = FuncLoader.LoadFunction<d_webkit_context_menu_item_new_separator>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Webkit), "webkit_context_menu_item_new_separator"));
|
|
|
|
public ContextMenuItem () : base (IntPtr.Zero)
|
|
{
|
|
if (GetType () != typeof (ContextMenuItem)) {
|
|
CreateNativeObject (Array.Empty<string> (), Array.Empty<GLib.Value> ());
|
|
return;
|
|
}
|
|
Raw = webkit_context_menu_item_new_separator();
|
|
}
|
|
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
|
delegate IntPtr d_webkit_context_menu_item_new_with_submenu(IntPtr label, IntPtr submenu);
|
|
static d_webkit_context_menu_item_new_with_submenu webkit_context_menu_item_new_with_submenu = FuncLoader.LoadFunction<d_webkit_context_menu_item_new_with_submenu>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Webkit), "webkit_context_menu_item_new_with_submenu"));
|
|
|
|
public ContextMenuItem (string label, WebKit.ContextMenu submenu) : base (IntPtr.Zero)
|
|
{
|
|
if (GetType () != typeof (ContextMenuItem)) {
|
|
var vals = new List<GLib.Value> ();
|
|
var names = new List<string> ();
|
|
CreateNativeObject (names.ToArray (), vals.ToArray ());
|
|
return;
|
|
}
|
|
IntPtr native_label = GLib.Marshaller.StringToPtrGStrdup (label);
|
|
Raw = webkit_context_menu_item_new_with_submenu(native_label, submenu == null ? IntPtr.Zero : submenu.Handle);
|
|
GLib.Marshaller.Free (native_label);
|
|
}
|
|
|
|
|
|
// Internal representation of the wrapped structure ABI.
|
|
static GLib.AbiStruct _class_abi = null;
|
|
static public unsafe new GLib.AbiStruct class_abi {
|
|
get {
|
|
if (_class_abi == null)
|
|
_class_abi = new GLib.AbiStruct (new List<GLib.AbiField>{
|
|
new GLib.AbiField("_webkit_reserved0"
|
|
, GLib.Object.class_abi.Fields
|
|
, (uint) sizeof( IntPtr ) // _webkit_reserved0
|
|
, null
|
|
, "_webkit_reserved1"
|
|
, (uint) sizeof(IntPtr)
|
|
, 0
|
|
),
|
|
new GLib.AbiField("_webkit_reserved1"
|
|
, -1
|
|
, (uint) sizeof( IntPtr ) // _webkit_reserved1
|
|
, "_webkit_reserved0"
|
|
, "_webkit_reserved2"
|
|
, (uint) sizeof(IntPtr)
|
|
, 0
|
|
),
|
|
new GLib.AbiField("_webkit_reserved2"
|
|
, -1
|
|
, (uint) sizeof( IntPtr ) // _webkit_reserved2
|
|
, "_webkit_reserved1"
|
|
, "_webkit_reserved3"
|
|
, (uint) sizeof(IntPtr)
|
|
, 0
|
|
),
|
|
new GLib.AbiField("_webkit_reserved3"
|
|
, -1
|
|
, (uint) sizeof( IntPtr ) // _webkit_reserved3
|
|
, "_webkit_reserved2"
|
|
, null
|
|
, (uint) sizeof(IntPtr)
|
|
, 0
|
|
),
|
|
});
|
|
|
|
return _class_abi;
|
|
}
|
|
}
|
|
|
|
|
|
// End of the ABI representation.
|
|
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
|
delegate IntPtr d_webkit_context_menu_item_get_type();
|
|
static d_webkit_context_menu_item_get_type webkit_context_menu_item_get_type = FuncLoader.LoadFunction<d_webkit_context_menu_item_get_type>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Webkit), "webkit_context_menu_item_get_type"));
|
|
|
|
public static new GLib.GType GType {
|
|
get {
|
|
IntPtr raw_ret = webkit_context_menu_item_get_type();
|
|
GLib.GType ret = new GLib.GType(raw_ret);
|
|
return ret;
|
|
}
|
|
}
|
|
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
|
delegate IntPtr d_webkit_context_menu_item_get_action(IntPtr raw);
|
|
static d_webkit_context_menu_item_get_action webkit_context_menu_item_get_action = FuncLoader.LoadFunction<d_webkit_context_menu_item_get_action>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Webkit), "webkit_context_menu_item_get_action"));
|
|
|
|
[Obsolete]
|
|
public Gtk.Action Action {
|
|
get {
|
|
IntPtr raw_ret = webkit_context_menu_item_get_action(Handle);
|
|
Gtk.Action ret = GLib.Object.GetObject(raw_ret) as Gtk.Action;
|
|
return ret;
|
|
}
|
|
}
|
|
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
|
delegate IntPtr d_webkit_context_menu_item_get_gaction(IntPtr raw);
|
|
static d_webkit_context_menu_item_get_gaction webkit_context_menu_item_get_gaction = FuncLoader.LoadFunction<d_webkit_context_menu_item_get_gaction>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Webkit), "webkit_context_menu_item_get_gaction"));
|
|
|
|
public GLib.IAction Gaction {
|
|
get {
|
|
IntPtr raw_ret = webkit_context_menu_item_get_gaction(Handle);
|
|
GLib.IAction ret = GLib.ActionAdapter.GetObject (raw_ret, false);
|
|
return ret;
|
|
}
|
|
}
|
|
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
|
delegate int d_webkit_context_menu_item_get_stock_action(IntPtr raw);
|
|
static d_webkit_context_menu_item_get_stock_action webkit_context_menu_item_get_stock_action = FuncLoader.LoadFunction<d_webkit_context_menu_item_get_stock_action>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Webkit), "webkit_context_menu_item_get_stock_action"));
|
|
|
|
public WebKit.ContextMenuAction StockAction {
|
|
get {
|
|
int raw_ret = webkit_context_menu_item_get_stock_action(Handle);
|
|
WebKit.ContextMenuAction ret = (WebKit.ContextMenuAction) raw_ret;
|
|
return ret;
|
|
}
|
|
}
|
|
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
|
delegate IntPtr d_webkit_context_menu_item_get_submenu(IntPtr raw);
|
|
static d_webkit_context_menu_item_get_submenu webkit_context_menu_item_get_submenu = FuncLoader.LoadFunction<d_webkit_context_menu_item_get_submenu>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Webkit), "webkit_context_menu_item_get_submenu"));
|
|
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
|
delegate void d_webkit_context_menu_item_set_submenu(IntPtr raw, IntPtr submenu);
|
|
static d_webkit_context_menu_item_set_submenu webkit_context_menu_item_set_submenu = FuncLoader.LoadFunction<d_webkit_context_menu_item_set_submenu>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Webkit), "webkit_context_menu_item_set_submenu"));
|
|
|
|
public WebKit.ContextMenu Submenu {
|
|
get {
|
|
IntPtr raw_ret = webkit_context_menu_item_get_submenu(Handle);
|
|
WebKit.ContextMenu ret = GLib.Object.GetObject(raw_ret) as WebKit.ContextMenu;
|
|
return ret;
|
|
}
|
|
set {
|
|
webkit_context_menu_item_set_submenu(Handle, value == null ? IntPtr.Zero : value.Handle);
|
|
}
|
|
}
|
|
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
|
delegate bool d_webkit_context_menu_item_is_separator(IntPtr raw);
|
|
static d_webkit_context_menu_item_is_separator webkit_context_menu_item_is_separator = FuncLoader.LoadFunction<d_webkit_context_menu_item_is_separator>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Webkit), "webkit_context_menu_item_is_separator"));
|
|
|
|
public bool IsSeparator {
|
|
get {
|
|
bool raw_ret = webkit_context_menu_item_is_separator(Handle);
|
|
bool ret = raw_ret;
|
|
return ret;
|
|
}
|
|
}
|
|
|
|
|
|
static ContextMenuItem ()
|
|
{
|
|
GtkSharp.WebkitGtkSharp.ObjectManager.Initialize ();
|
|
}
|
|
|
|
// Internal representation of the wrapped structure ABI.
|
|
static GLib.AbiStruct _abi_info = null;
|
|
static public unsafe new GLib.AbiStruct abi_info {
|
|
get {
|
|
if (_abi_info == null)
|
|
_abi_info = new GLib.AbiStruct (new List<GLib.AbiField>{
|
|
new GLib.AbiField("priv"
|
|
, GLib.Object.abi_info.Fields
|
|
, (uint) sizeof( IntPtr ) // priv
|
|
, null
|
|
, null
|
|
, (uint) sizeof(IntPtr)
|
|
, 0
|
|
),
|
|
});
|
|
|
|
return _abi_info;
|
|
}
|
|
}
|
|
|
|
|
|
// End of the ABI representation.
|
|
|
|
#endregion
|
|
}
|
|
}
|