added "guint disconnected : 1", we have enough space for flags now.

2006-04-07  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpobject.h: added "guint disconnected : 1", we
	have enough space for flags now.

	* app/core/gimpobject.c (gimp_object_dispose): use the new
	object->disconnected flag instead of attaching that boolean to the
	object.
This commit is contained in:
Michael Natterer 2006-04-07 15:39:17 +00:00 committed by Michael Natterer
parent d9a7a2c07e
commit a5bc7b0815
3 changed files with 14 additions and 6 deletions

View File

@ -1,3 +1,12 @@
2006-04-07 Michael Natterer <mitch@gimp.org>
* app/core/gimpobject.h: added "guint disconnected : 1", we
have enough space for flags now.
* app/core/gimpobject.c (gimp_object_dispose): use the new
object->disconnected flag instead of attaching that boolean to the
object.
2006-04-07 Sven Neumann <sven@gimp.org>
* app/xcf/xcf.c (xcf_loaders): declared the array as const.

View File

@ -117,15 +117,13 @@ gimp_object_init (GimpObject *object)
static void
gimp_object_dispose (GObject *object)
{
gboolean disconnected;
GimpObject *gimp_object = GIMP_OBJECT (object);
disconnected = GPOINTER_TO_INT (g_object_get_data (object, "disconnected"));
if (! disconnected)
if (! gimp_object->disconnected)
{
g_signal_emit (object, object_signals[DISCONNECT], 0);
g_object_set_data (object, "disconnected", GINT_TO_POINTER (TRUE));
gimp_object->disconnected = TRUE;
}
G_OBJECT_CLASS (parent_class)->dispose (object);

View File

@ -38,7 +38,8 @@ struct _GimpObject
/*< private >*/
gchar *normalized;
guint static_name : 1;
guint static_name : 1;
guint disconnected : 1;
};
struct _GimpObjectClass