Re: When is g_object_ref needed ?
- From: Tristan Van Berkom <tvb gnome org>
- To: Frédéric Terraza <fterraza free fr>
- Cc: gtk-list gnome org
- Subject: Re: When is g_object_ref needed ?
- Date: Mon, 03 Oct 2005 10:31:54 -0400
Frédéric Terraza wrote:
Hello,
I must use g_object_unref to free a gdk or a gtk object. There are lots
of deprecated functions that are now replaced by g_object_unref (such as
g_pixmap_unref, gdk_gc_unref).
But must I use g_object_ref after the creation of a pixmap or a gc,
since there used to be g_pixmap_ref and g_gc_ref functions ?
Yes,
they GdkPixmap & GdkGC are GObjects so they need to be unreffed.
(and the correct way to do this is to use g_object_unref).
Cheers,
-Tristan
http://developer.gnome.org/doc/API/2.0/gdk/gdk-Bitmaps-and-Pixmaps.html#gdk-pixmap-unref
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]