Re: gobject interface



Morten O. Hansen wrote:

Hi,

I have created an interface with base_init and base_finalize, and I have
derived on class from it. When i create the object, the base_init is
run, but the base_finalize is never run.. is there something besides
g_object_unref(object) i should run? do i have to unref the interface
somehow? There are no other objects using the interface, so the ref
should be 0.. (i have a g_print at the start of base_finalize, so it
should print something..)

Any ideas would be apprectiated...

Just shooting in the dark here... but... seems to me that
finalizing the iface when it is no longer used by default
might or might not be a good idea (performance-wise...
verses the usually small gain in memory)

If you want that behavior... maybe you are looking for
an argument to the GTypeInfo struct for that iface...
or a parameter to the type registering code, maybe
n_preallocs is not 0 ?

Cheers,
                             -Tristan




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]