Do not use static GTypeInfo and GInterfaceInfo
Either g_type_register_static_simple (used by G_DEFINE_TYPE_EXTENDED) and G_IMPLEMENT_INTERFACE use automatic variables for GTypeInfo and GInterfaceInfo structs, while tutorials and source code often use static variables. This commit consistently adopts the former method. https://bugzilla.gnome.org/show_bug.cgi?id=600158
This commit is contained in:
committed by
Javier Jardón
parent
e41f4e85cf
commit
1e1131c959
@ -30,7 +30,7 @@ gdk_colormap_get_type (void)
|
||||
|
||||
if (!object_type)
|
||||
{
|
||||
static const GTypeInfo object_info =
|
||||
const GTypeInfo object_info =
|
||||
{
|
||||
sizeof (GdkColormapClass),
|
||||
(GBaseInitFunc) NULL,
|
||||
|
||||
@ -59,7 +59,7 @@ gdk_drag_context_get_type (void)
|
||||
|
||||
if (!object_type)
|
||||
{
|
||||
static const GTypeInfo object_info =
|
||||
const GTypeInfo object_info =
|
||||
{
|
||||
sizeof (GdkDragContextClass),
|
||||
(GBaseInitFunc) NULL,
|
||||
|
||||
@ -687,7 +687,7 @@ gdk_drawable_impl_quartz_get_type (void)
|
||||
|
||||
if (!object_type)
|
||||
{
|
||||
static const GTypeInfo object_info =
|
||||
const GTypeInfo object_info =
|
||||
{
|
||||
sizeof (GdkDrawableImplQuartzClass),
|
||||
(GBaseInitFunc) NULL,
|
||||
|
||||
@ -169,7 +169,7 @@ _gdk_gc_quartz_get_type (void)
|
||||
|
||||
if (!object_type)
|
||||
{
|
||||
static const GTypeInfo object_info =
|
||||
const GTypeInfo object_info =
|
||||
{
|
||||
sizeof (GdkGCQuartzClass),
|
||||
(GBaseInitFunc) NULL,
|
||||
|
||||
@ -202,7 +202,7 @@ gdk_image_get_type (void)
|
||||
|
||||
if (!object_type)
|
||||
{
|
||||
static const GTypeInfo object_info =
|
||||
const GTypeInfo object_info =
|
||||
{
|
||||
sizeof (GdkImageClass),
|
||||
(GBaseInitFunc) NULL,
|
||||
|
||||
@ -29,7 +29,7 @@ gdk_device_get_type (void)
|
||||
|
||||
if (!object_type)
|
||||
{
|
||||
static const GTypeInfo object_info =
|
||||
const GTypeInfo object_info =
|
||||
{
|
||||
sizeof (GdkDeviceClass),
|
||||
(GBaseInitFunc) NULL,
|
||||
|
||||
@ -83,7 +83,7 @@ gdk_device_get_type (void)
|
||||
|
||||
if (!object_type)
|
||||
{
|
||||
static const GTypeInfo object_info =
|
||||
const GTypeInfo object_info =
|
||||
{
|
||||
sizeof (GdkDeviceClass),
|
||||
(GBaseInitFunc) NULL,
|
||||
|
||||
@ -102,7 +102,7 @@ _gdk_pixmap_impl_quartz_get_type (void)
|
||||
|
||||
if (!object_type)
|
||||
{
|
||||
static const GTypeInfo object_info =
|
||||
const GTypeInfo object_info =
|
||||
{
|
||||
sizeof (GdkPixmapImplQuartzClass),
|
||||
(GBaseInitFunc) NULL,
|
||||
|
||||
@ -47,7 +47,7 @@ gdk_visual_get_type (void)
|
||||
|
||||
if (!object_type)
|
||||
{
|
||||
static const GTypeInfo object_info =
|
||||
const GTypeInfo object_info =
|
||||
{
|
||||
sizeof (GdkVisualClass),
|
||||
(GBaseInitFunc) NULL,
|
||||
|
||||
Reference in New Issue
Block a user