summaryrefslogtreecommitdiffstats
path: root/src/widgets/sp-xmlview-tree.cpp
diff options
context:
space:
mode:
authorAlex Valavanis <valavanisalex@gmail.com>2011-06-24 10:23:41 +0000
committerAlex Valavanis <valavanisalex@gmail.com>2011-06-24 10:23:41 +0000
commit4d8bf28dbebbc70325c75c0501ed192ae330c63b (patch)
treebc31b7781d12de480edee237a1d419a8555718d1 /src/widgets/sp-xmlview-tree.cpp
parentRemove/replace deprecated gtk_window_set_policy symbol (diff)
downloadinkscape-4d8bf28dbebbc70325c75c0501ed192ae330c63b.tar.gz
inkscape-4d8bf28dbebbc70325c75c0501ed192ae330c63b.zip
Switch to GObject
(bzr r10350.1.3)
Diffstat (limited to 'src/widgets/sp-xmlview-tree.cpp')
-rw-r--r--src/widgets/sp-xmlview-tree.cpp24
1 files changed, 11 insertions, 13 deletions
diff --git a/src/widgets/sp-xmlview-tree.cpp b/src/widgets/sp-xmlview-tree.cpp
index b757123b5..e1779b620 100644
--- a/src/widgets/sp-xmlview-tree.cpp
+++ b/src/widgets/sp-xmlview-tree.cpp
@@ -125,25 +125,23 @@ sp_xmlview_tree_set_repr (SPXMLViewTree * tree, Inkscape::XML::Node * repr)
gtk_clist_thaw (GTK_CLIST (tree));
}
-GtkType
+GType
sp_xmlview_tree_get_type (void)
{
- //TODO: switch to GObject
- // GtkType and such calls were deprecated a while back with the
- // introduction of GObject as a separate layer, with GType instead. --JonCruz
-
- static GtkType type = 0;
+ static GType type = 0;
if (!type) {
- static const GtkTypeInfo info = {
- (gchar*) "SPXMLViewTree",
- sizeof (SPXMLViewTree),
+ static const GTypeInfo info = {
sizeof (SPXMLViewTreeClass),
- (GtkClassInitFunc) sp_xmlview_tree_class_init,
- (GtkObjectInitFunc) sp_xmlview_tree_init,
- NULL, NULL, NULL
+ NULL, NULL,
+ (GClassInitFunc) sp_xmlview_tree_class_init,
+ NULL, NULL,
+ sizeof (SPXMLViewTree),
+ 0,
+ (GInstanceInitFunc) sp_xmlview_tree_init,
+ NULL
};
- type = gtk_type_unique (GTK_TYPE_CTREE, &info);
+ type = g_type_register_static (GTK_TYPE_CTREE, "SPXMLViewTree", &info, (GTypeFlags)0);
}
return type;