Turn GKeyFile into a boxed for introspection

Using the new refcounting API, introduce a boxed type wrapping
GKeyFile and expose it introspection bindings in glib-types.h.
This commit is contained in:
Giovanni Campagna 2011-10-15 17:51:25 -04:00 committed by Matthias Clasen
parent a57c9148cf
commit 96817746d9
4 changed files with 14 additions and 0 deletions

View File

@ -355,6 +355,7 @@ G_TYPE_DATE_TIME
G_TYPE_IO_CHANNEL
G_TYPE_IO_CONDITION
G_TYPE_VARIANT_BUILDER
G_TYPE_KEY_FILE
G_TYPE_MAIN_CONTEXT
G_TYPE_MAIN_LOOP
G_TYPE_SOURCE

View File

@ -145,6 +145,8 @@ G_DEFINE_BOXED_TYPE (GVariantBuilder, g_variant_builder, g_variant_builder_ref,
G_DEFINE_BOXED_TYPE (GError, g_error, g_error_copy, g_error_free)
G_DEFINE_BOXED_TYPE (GDateTime, g_date_time, g_date_time_ref, g_date_time_unref);
G_DEFINE_BOXED_TYPE (GKeyFile, g_key_file, g_key_file_ref, g_key_file_unref)
G_DEFINE_BOXED_TYPE (GMainLoop, g_main_loop, g_main_loop_ref, g_main_loop_unref)
G_DEFINE_BOXED_TYPE (GMainContext, g_main_context, g_main_context_ref, g_main_context_unref)
G_DEFINE_BOXED_TYPE (GSource, g_source, g_source_ref, g_source_unref)

View File

@ -209,6 +209,15 @@ typedef gsize GType;
*/
#define G_TYPE_SOURCE (g_source_get_type ())
/**
* G_TYPE_KEY_FILE:
*
* The #GType for a boxed type holding a #GKeyFile.
*
* Since: 2.32
*/
#define G_TYPE_KEY_FILE (g_key_file_get_type ())
GType g_date_get_type (void) G_GNUC_CONST;
GType g_strv_get_type (void) G_GNUC_CONST;
GType g_gstring_get_type (void) G_GNUC_CONST;
@ -224,6 +233,7 @@ GType g_date_time_get_type (void) G_GNUC_CONST;
GType g_io_channel_get_type (void) G_GNUC_CONST;
GType g_io_condition_get_type (void) G_GNUC_CONST;
GType g_variant_builder_get_type (void) G_GNUC_CONST;
GType g_key_file_get_type (void) G_GNUC_CONST;
GType g_main_loop_get_type (void) G_GNUC_CONST;
GType g_main_context_get_type (void) G_GNUC_CONST;
GType g_source_get_type (void) G_GNUC_CONST;

View File

@ -27,6 +27,7 @@ g_regex_get_type
g_match_info_get_type
g_variant_builder_get_type
g_variant_type_get_gtype
g_key_file_get_type
g_main_loop_get_type
g_main_context_get_type
g_source_get_type