示例#1
0
 static void OverrideChildActivated(GLib.GType gtype, ChildActivatedNativeDelegate callback)
 {
     unsafe {
         IntPtr *raw_ptr = (IntPtr *)(((long)gtype.GetClassPtr()) + (long)class_abi.GetFieldOffset("child_activated"));
         *raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate)callback);
     }
 }
示例#2
0
        private void InternalChildActivated(Gtk.FlowBoxChild child)
        {
            ChildActivatedNativeDelegate unmanaged = class_abi.BaseOverride <ChildActivatedNativeDelegate>(this.LookupGType(), "child_activated");

            if (unmanaged == null)
            {
                return;
            }

            unmanaged(this.Handle, child == null ? IntPtr.Zero : child.Handle);
        }
示例#3
0
        private void InternalChildActivated(Gtk.FlowBoxChild child)
        {
            ChildActivatedNativeDelegate unmanaged = null;

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

            unmanaged(this.Handle, child == null ? IntPtr.Zero : child.Handle);
        }