static void OverrideFull(GLib.GType gtype, FullNativeDelegate callback) { unsafe { IntPtr *raw_ptr = (IntPtr *)(((long)gtype.GetClassPtr()) + (long)class_abi.GetFieldOffset("full")); *raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate)callback); } }
private void InternalFull() { FullNativeDelegate unmanaged = null; unsafe { IntPtr *raw_ptr = (IntPtr *)(((long)this.LookupGType().GetThresholdType().GetClassPtr()) + (long)class_abi.GetFieldOffset("full")); unmanaged = (FullNativeDelegate)Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(FullNativeDelegate)); } if (unmanaged == null) { return; } unmanaged(this.Handle); }