Commit c09cc893 authored by Matthias Clasen's avatar Matthias Clasen Committed by Matthias Clasen
Browse files

Intern type names in code generated by glib-mkenums, too.

2005-08-31  Matthias Clasen  <mclasen@redhat.com>

	* gdk/Makefile.am:
	* gtk/Makefile.am: Intern type names in code generated by
	glib-mkenums, too.

	* gtk/*.c:
	* gdk/x11/*.c:
	* gdk/*.c: Intern type names before registering the type to avoid
	unnecessary copies.
parent f55cffb0
2005-08-31 Matthias Clasen <mclasen@redhat.com>
* gdk/x11/gdkwindow-x11.c (gdk_window_impl_x11_get_type):
* gdk/x11/gdkscreen-x11.c (_gdk_screen_x11_get_type):
* gdk/x11/gdkpixmap-x11.c (gdk_pixmap_impl_x11_get_type):
* gdk/x11/gdkkeys-x11.c (gdk_keymap_x11_get_type):
* gdk/x11/gdkinput.c (gdk_device_get_type):
* gdk/x11/gdkimage-x11.c (gdk_image_get_type):
* gdk/x11/gdkgc-x11.c (_gdk_gc_x11_get_type):
* gdk/x11/gdkdrawable-x11.c (_gdk_drawable_impl_x11_get_type):
* gdk/x11/gdkdnd-x11.c (gdk_drag_context_get_type):
* gdk/x11/gdkdisplay-x11.c (_gdk_display_x11_get_type):
* gdk/x11/gdkcolor-x11.c (gdk_colormap_get_type):
* gdk/gdkwindow.c (gdk_window_object_get_type):
* gdk/gdkscreen.c (gdk_screen_get_type):
* gdk/gdkrectangle.c (gdk_rectangle_get_type):
* gdk/gdkpixmap.c (gdk_pixmap_get_type):
* gdk/gdkkeys.c (gdk_keymap_get_type):
* gdk/gdkfont.c (gdk_font_get_type):
* gdk/gdkevents.c (gdk_event_get_type):
* gdk/gdkdraw.c (gdk_drawable_get_type):
* gdk/gdkdisplaymanager.c (gdk_display_manager_get_type):
* gdk/gdkdisplay.c (gdk_display_get_type):
* gdk/gdkcursor.c (gdk_cursor_get_type):
* gdk/gdkcolor.c (gdk_color_get_type): Intern type names before
registering the type to avoid unnecessary copies.
* gdk/Makefile.am:
* gtk/Makefile.am: Intern type names in code generated by
glib-mkenums, too.
* gtk/*.c:
* gdk/x11/*.c:
* gdk/*.c: Intern type names before registering the type to avoid
unnecessary copies.
* configure.in: Require GLib 2.9.0
......
2005-08-31 Matthias Clasen <mclasen@redhat.com>
* gdk/x11/gdkwindow-x11.c (gdk_window_impl_x11_get_type):
* gdk/x11/gdkscreen-x11.c (_gdk_screen_x11_get_type):
* gdk/x11/gdkpixmap-x11.c (gdk_pixmap_impl_x11_get_type):
* gdk/x11/gdkkeys-x11.c (gdk_keymap_x11_get_type):
* gdk/x11/gdkinput.c (gdk_device_get_type):
* gdk/x11/gdkimage-x11.c (gdk_image_get_type):
* gdk/x11/gdkgc-x11.c (_gdk_gc_x11_get_type):
* gdk/x11/gdkdrawable-x11.c (_gdk_drawable_impl_x11_get_type):
* gdk/x11/gdkdnd-x11.c (gdk_drag_context_get_type):
* gdk/x11/gdkdisplay-x11.c (_gdk_display_x11_get_type):
* gdk/x11/gdkcolor-x11.c (gdk_colormap_get_type):
* gdk/gdkwindow.c (gdk_window_object_get_type):
* gdk/gdkscreen.c (gdk_screen_get_type):
* gdk/gdkrectangle.c (gdk_rectangle_get_type):
* gdk/gdkpixmap.c (gdk_pixmap_get_type):
* gdk/gdkkeys.c (gdk_keymap_get_type):
* gdk/gdkfont.c (gdk_font_get_type):
* gdk/gdkevents.c (gdk_event_get_type):
* gdk/gdkdraw.c (gdk_drawable_get_type):
* gdk/gdkdisplaymanager.c (gdk_display_manager_get_type):
* gdk/gdkdisplay.c (gdk_display_get_type):
* gdk/gdkcursor.c (gdk_cursor_get_type):
* gdk/gdkcolor.c (gdk_color_get_type): Intern type names before
registering the type to avoid unnecessary copies.
* gdk/Makefile.am:
* gtk/Makefile.am: Intern type names in code generated by
glib-mkenums, too.
* gtk/*.c:
* gdk/x11/*.c:
* gdk/*.c: Intern type names before registering the type to avoid
unnecessary copies.
* configure.in: Require GLib 2.9.0
......
2005-08-31 Matthias Clasen <mclasen@redhat.com>
* Makefile.am (gdk-pixbuf-enum-types.c): Intern type
names in code generated by glib-mkenums, too.
* io-ani-animation.c (gdk_pixbuf_ani_anim_iter_get_type)
(gdk_pixbuf_ani_anim_get_type):
* io-gif-animation.c (gdk_pixbuf_gif_anim_get_type)
......
......@@ -393,7 +393,7 @@ gdk-pixbuf-enum-types.c: @REBUILD@ $(gdk_pixbuf_headers) Makefile
--ftail "\n#define __GDK_PIXBUF_ENUM_TYPES_C__\n#include \"gdk-pixbuf-aliasdef.c\"" \
--vhead "GType\n@enum_name@_get_type (void)\n{\n static GType etype = 0;\n if (etype == 0) {\n static const G@Type@Value values[] = {" \
--vprod " { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
--vtail " { 0, NULL, NULL }\n };\n etype = g_@type@_register_static (\"@EnumName@\", values);\n }\n return etype;\n}\n" \
--vtail " { 0, NULL, NULL }\n };\n etype = g_@type@_register_static (g_intern_static_string (\"@EnumName@\"), values);\n }\n return etype;\n}\n" \
$(gdk_pixbuf_headers)) > gdk-pixbuf-enum-types.c
#
......
......@@ -250,7 +250,7 @@ gdkenumtypes.c: @REBUILD@ $(gdk_public_h_sources) Makefile
--ftail "\n#define __GDK_ENUM_TYPES_C__\n#include \"gdkaliasdef.c\"\n" \
--vhead "GType\n@enum_name@_get_type (void)\n{\n static GType etype = 0;\n if (etype == 0) {\n static const G@Type@Value values[] = {" \
--vprod " { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
--vtail " { 0, NULL, NULL }\n };\n etype = g_@type@_register_static (\"@EnumName@\", values);\n }\n return etype;\n}\n" \
--vtail " { 0, NULL, NULL }\n };\n etype = g_@type@_register_static (g_intern_static_string (\"@EnumName@\"), values);\n }\n return etype;\n}\n" \
$(gdk_public_h_sources) ) > xgen-getc \
&& cp xgen-getc gdkenumtypes.c \
&& rm -f xgen-getc
......
......@@ -658,7 +658,7 @@ gtktypebuiltins.c: @REBUILD@ $(gtk_public_h_sources) Makefile
--fprod "\n/* enumerations from \"@filename@\" */" \
--vhead "GType\n@enum_name@_get_type (void)\n{\n static GType etype = 0;\n if (etype == 0) {\n static const G@Type@Value values[] = {" \
--vprod " { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
--vtail " { 0, NULL, NULL }\n };\n etype = g_@type@_register_static (\"@EnumName@\", values);\n }\n return etype;\n}\n" \
--vtail " { 0, NULL, NULL }\n };\n etype = g_@type@_register_static (g_intern_static_string (\"@EnumName@\"), values);\n }\n return etype;\n}\n" \
$(gtk_public_h_sources) ) > xgen-gtbc \
&& cp xgen-gtbc gtktypebuiltins.c \
&& rm -f xgen-gtbc
......
......@@ -78,7 +78,7 @@ gtk_accel_group_get_type (void)
(GInstanceInitFunc) gtk_accel_group_init,
};
object_type = g_type_register_static (G_TYPE_OBJECT, "GtkAccelGroup",
object_type = g_type_register_static (G_TYPE_OBJECT, g_intern_static_string ("GtkAccelGroup"),
&object_info, 0);
}
......
......@@ -85,7 +85,7 @@ gtk_accel_label_get_type (void)
};
accel_label_type =
g_type_register_static (GTK_TYPE_LABEL, "GtkAccelLabel",
g_type_register_static (GTK_TYPE_LABEL, g_intern_static_string ("GtkAccelLabel"),
&accel_label_info, 0);
}
......
......@@ -49,7 +49,7 @@ gtk_accessible_get_type (void)
};
accessible_type =
g_type_register_static (ATK_TYPE_OBJECT, "GtkAccessible",
g_type_register_static (ATK_TYPE_OBJECT, g_intern_static_string ("GtkAccessible"),
&accessible_info, 0);
}
......
......@@ -132,7 +132,7 @@ gtk_action_get_type (void)
};
type = g_type_register_static (G_TYPE_OBJECT,
"GtkAction",
g_intern_static_string ("GtkAction"),
&type_info, 0);
}
return type;
......
......@@ -106,7 +106,7 @@ gtk_action_group_get_type (void)
(GInstanceInitFunc) gtk_action_group_init,
};
type = g_type_register_static (G_TYPE_OBJECT, "GtkActionGroup",
type = g_type_register_static (G_TYPE_OBJECT, g_intern_static_string ("GtkActionGroup"),
&type_info, 0);
}
......
......@@ -85,7 +85,7 @@ gtk_adjustment_get_type (void)
};
adjustment_type =
g_type_register_static (GTK_TYPE_OBJECT, "GtkAdjustment",
g_type_register_static (GTK_TYPE_OBJECT, g_intern_static_string ("GtkAdjustment"),
&adjustment_info, 0);
}
......
......@@ -91,7 +91,7 @@ gtk_alignment_get_type (void)
(GInstanceInitFunc) gtk_alignment_init,
};
alignment_type = g_type_register_static (GTK_TYPE_BIN, "GtkAlignment",
alignment_type = g_type_register_static (GTK_TYPE_BIN, g_intern_static_string ("GtkAlignment"),
&alignment_info, 0);
}
......
......@@ -76,7 +76,7 @@ gtk_arrow_get_type (void)
(GInstanceInitFunc) gtk_arrow_init,
};
arrow_type = g_type_register_static (GTK_TYPE_MISC, "GtkArrow",
arrow_type = g_type_register_static (GTK_TYPE_MISC, g_intern_static_string ("GtkArrow"),
&arrow_info, 0);
}
......
......@@ -82,7 +82,7 @@ gtk_aspect_frame_get_type (void)
};
aspect_frame_type =
g_type_register_static (GTK_TYPE_FRAME, "GtkAspectFrame",
g_type_register_static (GTK_TYPE_FRAME, g_intern_static_string ("GtkAspectFrame"),
&aspect_frame_info, 0);
}
......
......@@ -89,7 +89,7 @@ gtk_button_box_get_type (void)
};
button_box_type =
g_type_register_static (GTK_TYPE_BOX, "GtkButtonBox",
g_type_register_static (GTK_TYPE_BOX, g_intern_static_string ("GtkButtonBox"),
&button_box_info, G_TYPE_FLAG_ABSTRACT);
}
......
......@@ -66,7 +66,7 @@ gtk_bin_get_type (void)
NULL, /* value_table */
};
bin_type = g_type_register_static (GTK_TYPE_CONTAINER, "GtkBin",
bin_type = g_type_register_static (GTK_TYPE_CONTAINER, g_intern_static_string ("GtkBin"),
&bin_info, G_TYPE_FLAG_ABSTRACT);
}
......
......@@ -100,7 +100,7 @@ gtk_box_get_type (void)
NULL, /* value_table */
};
box_type = g_type_register_static (GTK_TYPE_CONTAINER, "GtkBox",
box_type = g_type_register_static (GTK_TYPE_CONTAINER, g_intern_static_string ("GtkBox"),
&box_info, G_TYPE_FLAG_ABSTRACT);
}
......
......@@ -165,7 +165,7 @@ gtk_button_get_type (void)
(GInstanceInitFunc) gtk_button_init,
};
button_type = g_type_register_static (GTK_TYPE_BIN, "GtkButton",
button_type = g_type_register_static (GTK_TYPE_BIN, g_intern_static_string ("GtkButton"),
&button_info, 0);
}
......
......@@ -46,7 +46,7 @@ gtk_cell_editable_get_type (void)
};
cell_editable_type =
g_type_register_static (G_TYPE_INTERFACE, "GtkCellEditable",
g_type_register_static (G_TYPE_INTERFACE, g_intern_static_string ("GtkCellEditable"),
&cell_editable_info, 0);
g_type_interface_add_prerequisite (cell_editable_type, GTK_TYPE_WIDGET);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment