summaryrefslogtreecommitdiff
path: root/gobject/gtype.c
diff options
context:
space:
mode:
authorTim Janik <timj@gtk.org>2001-06-19 12:13:22 +0000
committerTim Janik <timj@src.gnome.org>2001-06-19 12:13:22 +0000
commit3b346e3581a07188435ba1623f17b8b46ade1030 (patch)
tree66aaf475ce4bd9c4b518061b3484b6892b5c1191 /gobject/gtype.c
parentefc2ec72b5061346ed325f5fa008f4e92759c750 (diff)
remove left-over usages of an anonymous GBoxed typedef.
Mon Jun 11 17:07:06 2001 Tim Janik <timj@gtk.org> * gboxed.[hc]: remove left-over usages of an anonymous GBoxed typedef. * gobjectnotifyqueue.c: moved property notify queue implementation bits into this function. * gparam.[hc]: added g_param_spec_pool_belongings(), completed g_param_spec_pool_list(). added GParameter for _setv() functions. * gobject.[hc]: use gobjectnotifyqueue.h implementation now. got rid of properties_changed signal. new functions g_object_newv(), g_object_class_list_properties(). removed "properties_changed" signal. * gtype.[hc]: added g_type_depth() to figure number of parent types + 1 for a type. * gsignal.h: add g_signal_connect() (as per owen's request) and g_signal_connect_swapped().
Diffstat (limited to 'gobject/gtype.c')
-rw-r--r--gobject/gtype.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/gobject/gtype.c b/gobject/gtype.c
index 590598c57..664580be3 100644
--- a/gobject/gtype.c
+++ b/gobject/gtype.c
@@ -2073,6 +2073,18 @@ g_type_parent (GType type)
return node ? NODE_PARENT_TYPE (node) : 0;
}
+guint
+g_type_depth (GType type)
+{
+ TypeNode *node;
+
+ G_READ_LOCK (&type_rw_lock);
+ node = lookup_type_node_L (type);
+ G_READ_UNLOCK (&type_rw_lock);
+
+ return node ? node->n_supers + 1 : 0;
+}
+
GType
g_type_next_base (GType type,
GType base_type)