use g_type_is_a() to check for object_type being a G_TYPE_OBJECT, not

Fri Mar  9 10:14:00 2001  Tim Janik  <timj@gtk.org>

        * gparamspecs.c (g_param_spec_object): use g_type_is_a() to check
        for object_type being a G_TYPE_OBJECT, not G_TYPE_IS_OBJECT(), since
        that wouldn't allow interface types.

        * gtype.c (g_type_interface_add_prerequisite): arg, fixed small cnp bug
        with bad implications and an off-by-one error.
This commit is contained in:
Tim Janik
2001-03-09 09:14:32 +00:00
committed by Tim Janik
parent 64fd11dfe7
commit ae5764c57e
5 changed files with 27 additions and 19 deletions

View File

@@ -1587,7 +1587,7 @@ g_param_spec_object (const gchar *name,
{
GParamSpecObject *ospec;
g_return_val_if_fail (G_TYPE_IS_OBJECT (object_type), NULL);
g_return_val_if_fail (g_type_is_a (object_type, G_TYPE_OBJECT), NULL);
ospec = g_param_spec_internal (G_TYPE_PARAM_OBJECT,
name,