Boxed type for MSValue

master
Yevgen Muntyan 2006-05-24 02:02:18 -05:00
parent ce317eba54
commit 1abb512cb3
2 changed files with 19 additions and 0 deletions

View File

@ -1616,3 +1616,17 @@ ms_vaprintf (const char *format,
return g_string_free (buffer, FALSE);
}
GType
ms_value_get_type (void)
{
static GType type;
if (!type)
type = g_boxed_type_register_static ("MSValue",
(GBoxedCopyFunc) ms_value_ref,
(GBoxedFreeFunc) ms_value_unref);
return type;
}

View File

@ -19,6 +19,9 @@
G_BEGIN_DECLS
#define MS_TYPE_VALUE (ms_value_get_type ())
typedef struct _MSValue MSValue;
typedef struct _MSValueClass MSValueClass;
typedef struct _MSFunc MSFunc;
@ -92,6 +95,8 @@ struct _MSValue {
};
GType ms_value_get_type (void) G_GNUC_CONST;
void ms_type_init (void);
void _ms_type_init_builtin (MSValueClass *types);