[Gtk-sharp-list] Medsphere.Widgets.FBox crashes with "must provide a protected or public IntPtr ctor"
Adam Tauno Williams
awilliam at whitemice.org
Tue Nov 4 07:43:40 EST 2008
I've create a widget that extends the very cool Medsphere FBox
public class PhoneTable : Medsphere.Widgets.FBox
{
public PhoneTable(Whitemice.ZOGI.Company company) : base()
{
...
}
}
And it works for awhile. Then it crashes with -
Exception in Gtk# callback delegate
Note: Applications can use GLib.ExceptionManager.UnhandledException to
handle the exception.
GLib.MissingIntPtrCtorException: GLib.Object subclass
Whitemice.ZOGI.GtkWidgets.PhoneTable must provide a protected or public
IntPtr ctor to support wrapping of native object handles.
at GLib.ObjectManager.CreateObject (IntPtr raw) [0x00000]
at GLib.Object.GetObject (IntPtr o, Boolean owned_ref) [0x00000]
at Gtk.Container.Forall_cb (IntPtr container, Boolean
include_internals, IntPtr cb, IntPtr data) [0x00000]
at GLib.ExceptionManager.RaiseUnhandledException(System.Exception e,
Boolean is_terminal)
at Gtk.Container.Forall_cb(IntPtr container, Boolean
include_internals, IntPtr cb, IntPtr data)
at GLib.ToggleRef.g_object_remove_toggle_ref(IntPtr ,
GLib.ToggleNotifyHandler , IntPtr )
at GLib.ToggleRef.Free()
at GLib.Object.PerformQueuedUnrefs()
at GLib.Timeout+TimeoutProxy.Handler()
at Gtk.Application.gtk_main()
at Gtk.Application.Run()
at Whitemice.Consonance.Consonance.Main(System.String[] args)
It seems like it happens as soon as an FBox has been disposed. Is there
something different with the Medsphere widgets? I've bene using Gtk#
for years and never had to deal with an IntPtr.
More information about the Gtk-sharp-list
mailing list