Update to use the new g_boxed_type_register_static API.

2001-09-10  Alex Larsson  <alexl@redhat.com>

	* demos/gtk-demo/stock_browser.c:
	* gdk/gdkcolor.c:
	* gdk/gdkcursor.c:
	* gdk/gdkevents.c:
	* gdk/gdkrectangle.c:
	* gtk/gtktypeutils.c:
	Update to use the new g_boxed_type_register_static API.
This commit is contained in:
Alex Larsson 2001-09-10 16:54:07 +00:00 committed by Alexander Larsson
parent 63a9502159
commit 1a69c439de
13 changed files with 76 additions and 31 deletions

View File

@ -1,3 +1,13 @@
2001-09-10 Alex Larsson <alexl@redhat.com>
* demos/gtk-demo/stock_browser.c:
* gdk/gdkcolor.c:
* gdk/gdkcursor.c:
* gdk/gdkevents.c:
* gdk/gdkrectangle.c:
* gtk/gtktypeutils.c:
Update to use the new g_boxed_type_register_static API.
2001-09-10 Padraig O'Briain <padraig.obriain@sun.com>
* gtk/gtktreestore.c:

View File

@ -1,3 +1,13 @@
2001-09-10 Alex Larsson <alexl@redhat.com>
* demos/gtk-demo/stock_browser.c:
* gdk/gdkcolor.c:
* gdk/gdkcursor.c:
* gdk/gdkevents.c:
* gdk/gdkrectangle.c:
* gtk/gtktypeutils.c:
Update to use the new g_boxed_type_register_static API.
2001-09-10 Padraig O'Briain <padraig.obriain@sun.com>
* gtk/gtktreestore.c:

View File

@ -1,3 +1,13 @@
2001-09-10 Alex Larsson <alexl@redhat.com>
* demos/gtk-demo/stock_browser.c:
* gdk/gdkcolor.c:
* gdk/gdkcursor.c:
* gdk/gdkevents.c:
* gdk/gdkrectangle.c:
* gtk/gtktypeutils.c:
Update to use the new g_boxed_type_register_static API.
2001-09-10 Padraig O'Briain <padraig.obriain@sun.com>
* gtk/gtktreestore.c:

View File

@ -1,3 +1,13 @@
2001-09-10 Alex Larsson <alexl@redhat.com>
* demos/gtk-demo/stock_browser.c:
* gdk/gdkcolor.c:
* gdk/gdkcursor.c:
* gdk/gdkevents.c:
* gdk/gdkrectangle.c:
* gtk/gtktypeutils.c:
Update to use the new g_boxed_type_register_static API.
2001-09-10 Padraig O'Briain <padraig.obriain@sun.com>
* gtk/gtktreestore.c:

View File

@ -1,3 +1,13 @@
2001-09-10 Alex Larsson <alexl@redhat.com>
* demos/gtk-demo/stock_browser.c:
* gdk/gdkcolor.c:
* gdk/gdkcursor.c:
* gdk/gdkevents.c:
* gdk/gdkrectangle.c:
* gtk/gtktypeutils.c:
Update to use the new g_boxed_type_register_static API.
2001-09-10 Padraig O'Briain <padraig.obriain@sun.com>
* gtk/gtktreestore.c:

View File

@ -1,3 +1,13 @@
2001-09-10 Alex Larsson <alexl@redhat.com>
* demos/gtk-demo/stock_browser.c:
* gdk/gdkcolor.c:
* gdk/gdkcursor.c:
* gdk/gdkevents.c:
* gdk/gdkrectangle.c:
* gtk/gtktypeutils.c:
Update to use the new g_boxed_type_register_static API.
2001-09-10 Padraig O'Briain <padraig.obriain@sun.com>
* gtk/gtktreestore.c:

View File

@ -1,3 +1,13 @@
2001-09-10 Alex Larsson <alexl@redhat.com>
* demos/gtk-demo/stock_browser.c:
* gdk/gdkcolor.c:
* gdk/gdkcursor.c:
* gdk/gdkevents.c:
* gdk/gdkrectangle.c:
* gtk/gtktypeutils.c:
Update to use the new g_boxed_type_register_static API.
2001-09-10 Padraig O'Briain <padraig.obriain@sun.com>
* gtk/gtktreestore.c:

View File

@ -65,10 +65,8 @@ stock_item_info_get_type (void)
if (our_type == 0)
our_type = g_boxed_type_register_static ("StockItemInfo",
NULL,
(GBoxedCopyFunc) stock_item_info_copy,
(GBoxedFreeFunc) stock_item_info_free,
FALSE);
(GBoxedFreeFunc) stock_item_info_free);
return our_type;
}

View File

@ -224,9 +224,7 @@ gdk_color_get_type (void)
if (our_type == 0)
our_type = g_boxed_type_register_static ("GdkColor",
NULL,
(GBoxedCopyFunc)gdk_color_copy,
(GBoxedFreeFunc)gdk_color_free,
FALSE);
(GBoxedFreeFunc)gdk_color_free);
return our_type;
}

View File

@ -34,10 +34,8 @@ gdk_cursor_get_type (void)
if (our_type == 0)
our_type = g_boxed_type_register_static ("GdkCursor",
NULL,
(GBoxedCopyFunc)gdk_cursor_ref,
(GBoxedFreeFunc)gdk_cursor_unref,
TRUE);
(GBoxedFreeFunc)gdk_cursor_unref);
return our_type;
}

View File

@ -1000,10 +1000,8 @@ gdk_event_get_type (void)
if (our_type == 0)
our_type = g_boxed_type_register_static ("GdkEvent",
NULL,
(GBoxedCopyFunc)gdk_event_copy,
(GBoxedFreeFunc)gdk_event_free,
FALSE);
(GBoxedFreeFunc)gdk_event_free);
return our_type;
}

View File

@ -98,10 +98,8 @@ gdk_rectangle_get_type (void)
if (our_type == 0)
our_type = g_boxed_type_register_static ("GdkRectangle",
NULL,
(GBoxedCopyFunc)gdk_rectangle_copy,
(GBoxedFreeFunc)g_free,
FALSE);
(GBoxedFreeFunc)g_free);
return our_type;
}

View File

@ -169,25 +169,10 @@ gtk_type_init (GTypeDebugFlags debug_flags)
type_id = g_flags_register_static (builtin_info[i].type_name, builtin_info[i].pointer1);
else if (builtin_info[i].parent == GTK_TYPE_BOXED)
{
static const gchar *copy_types[] = {
"GtkSelectionData", "GtkBorder", "GtkTextIter", "PangoTabArray",
"PangoFontDescription", "GtkTreeIter", "GtkTreePath", "GtkRequisition"
};
gboolean ref_counted = TRUE;
guint j;
for (j = 0; j < sizeof (copy_types) / sizeof (copy_types[0]); j++)
if (strcmp (copy_types[j], builtin_info[i].type_name) == 0)
{
ref_counted = FALSE;
break;
}
if (builtin_info[i].pointer1 && builtin_info[i].pointer2)
type_id = g_boxed_type_register_static (builtin_info[i].type_name,
NULL,
builtin_info[i].pointer1,
builtin_info[i].pointer2,
ref_counted);
builtin_info[i].pointer2);
else
type_id = g_type_register_static (GTK_TYPE_BOXED, builtin_info[i].type_name, &tinfo, 0);
}