gobject - A few questinons



Hi there!

I have got a few questions, I couln't figure out or I didn't understand
the Manual/Tutorials I read.

When I inherit an object from another object, I do that with
g_type_register_static () with the first parameter.  Ok.

When I have parent objects created by myselfe, where do I set default
values for variables?  Is it ok to do that in my_object_instance_init
()?
Or should I use the constructor for that?

I have one parent which stores some simple information about my object.
The declaration for this is the struct for the parent instance.  When I
use that in a child object, do I have a copy of the parent there?  Or do
I have to cast with MY_PARENTOBJ (self) to get this variables, declared
there?

Can I use this variables more than one time?  Like:  child->data and
parent->data or are this variables equal, do they exist both or only
one?

Thanks for your help (even if there will come more questions soon.
Please tell my if this is the right mailling list.

Martin




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