On 11/27/2010 05:32 PM, Jannis Pohlmann wrote:
On Sat, 27 Nov 2010 12:14:39 +0100
Jaroslav Šmíd<jardas...@gmail.com>  wrote:

Is it possible to "cancel" construction in gobject-derived class?

Lets say I have GMyObject derived from GObject. In its init function
I need to spawn a thread. When that fails, I would like to cancel
construction of the object (so that gobjectclass' finalize function
would be called on the object and g_object_new would return
null-pointer).

Have a look at the GInitable and GAsyncInitable interfaces.

   - Jannis



_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Cool, thanks.
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Reply via email to