diff options
author | Tim Janik <timj@imendio.com> | 2005-12-22 15:07:03 +0000 |
---|---|---|
committer | Tim Janik <timj@src.gnome.org> | 2005-12-22 15:07:03 +0000 |
commit | 6f01d0c34f0d217b91a55ef1ec1b04d007259993 (patch) | |
tree | 240bd465a0323fe64bb08ac99aec255502bdc0ab /gobject/gparamspecs.h | |
parent | 513be6bbaec4f6f8675feaa3a29a41a1d04af5e1 (diff) | |
download | glib-6f01d0c34f0d217b91a55ef1ec1b04d007259993.tar.gz |
implemented G_TYPE_GTPYE. applied patch from matthias which implements
Thu Dec 22 14:59:24 2005 Tim Janik <timj@imendio.com>
* gvaluetypes.[hc]: implemented G_TYPE_GTPYE. applied patch
from matthias which implements GType accessors for GValue.
* gparamspecs.[hc]: applied patch from matthias which
implements G_TYPE_PARAM_GTYPE.
* gobject.[hc]:
GUnowned: introduced a new object type that has an initially
floating reference.
g_object_compat_control(): allow setting of a floating flag handler.
Diffstat (limited to 'gobject/gparamspecs.h')
-rw-r--r-- | gobject/gparamspecs.h | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/gobject/gparamspecs.h b/gobject/gparamspecs.h index 137e1d0bb..b6add1cbf 100644 --- a/gobject/gparamspecs.h +++ b/gobject/gparamspecs.h @@ -96,6 +96,9 @@ G_BEGIN_DECLS #define G_TYPE_PARAM_OVERRIDE (g_param_spec_types[20]) #define G_IS_PARAM_SPEC_OVERRIDE(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_OVERRIDE)) #define G_PARAM_SPEC_OVERRIDE(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_OVERRIDE, GParamSpecOverride)) +#define G_TYPE_PARAM_GTYPE (g_param_spec_types[21]) +#define G_IS_PARAM_SPEC_GTYPE(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_GTYPE)) +#define G_PARAM_SPEC_GTYPE(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_GTYPE, GParamSpecGType)) /* --- typedefs & structures --- */ @@ -120,6 +123,7 @@ typedef struct _GParamSpecPointer GParamSpecPointer; typedef struct _GParamSpecValueArray GParamSpecValueArray; typedef struct _GParamSpecObject GParamSpecObject; typedef struct _GParamSpecOverride GParamSpecOverride; +typedef struct _GParamSpecGType GParamSpecGType; struct _GParamSpecChar { @@ -268,6 +272,11 @@ struct _GParamSpecOverride GParamSpec parent_instance; GParamSpec *overridden; }; +struct _GParamSpecGType +{ + GParamSpec parent_instance; + GType is_a_type; +}; /* --- GParamSpec prototypes --- */ GParamSpec* g_param_spec_char (const gchar *name, @@ -391,9 +400,13 @@ GParamSpec* g_param_spec_object (const gchar *name, const gchar *blurb, GType object_type, GParamFlags flags); - GParamSpec* g_param_spec_override (const gchar *name, GParamSpec *overridden); +GParamSpec* g_param_spec_gtype (const gchar *name, + const gchar *nick, + const gchar *blurb, + GType is_a_type, + GParamFlags flags); /* --- internal --- */ /* We prefix variable declarations so they can |