コード例 #1
0
 static void OverrideFocusChildSet(GLib.GType gtype, FocusChildSetNativeDelegate callback)
 {
     unsafe {
         IntPtr *raw_ptr = (IntPtr *)(((long)gtype.GetClassPtr()) + (long)class_abi.GetFieldOffset("set_focus_child"));
         *raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate)callback);
     }
 }
コード例 #2
0
        private void InternalFocusChildSet(Gtk.Widget child)
        {
            FocusChildSetNativeDelegate unmanaged = class_abi.BaseOverride <FocusChildSetNativeDelegate>(this.LookupGType(), "set_focus_child");

            if (unmanaged == null)
            {
                return;
            }

            unmanaged(this.Handle, child == null ? IntPtr.Zero : child.Handle);
        }
コード例 #3
0
        private void InternalFocusChildSet(Gtk.Widget child)
        {
            FocusChildSetNativeDelegate unmanaged = null;

            unsafe {
                IntPtr *raw_ptr = (IntPtr *)(((long)this.LookupGType().GetThresholdType().GetClassPtr()) + (long)class_abi.GetFieldOffset("set_focus_child"));
                unmanaged = (FocusChildSetNativeDelegate)Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(FocusChildSetNativeDelegate));
            }
            if (unmanaged == null)
            {
                return;
            }

            unmanaged(this.Handle, child == null ? IntPtr.Zero : child.Handle);
        }
コード例 #4
0
ファイル: Container.cs プロジェクト: akrisiun/gtk-sharp
		static void OverrideFocusChildSet (GLib.GType gtype, FocusChildSetNativeDelegate callback)
		{
			gtksharp_container_override_set_focus_child (gtype.GetClassPtr (), callback);
		}
コード例 #5
0
ファイル: Container.cs プロジェクト: akrisiun/gtk-sharp
		static extern void gtksharp_container_override_set_focus_child (IntPtr class_struct, FocusChildSetNativeDelegate cb);