summaryrefslogtreecommitdiffstats
path: root/src/widgets/button.cpp
diff options
context:
space:
mode:
authorJon A. Cruz <jon@joncruz.org>2008-05-06 07:33:22 +0000
committerjoncruz <joncruz@users.sourceforge.net>2008-05-06 07:33:22 +0000
commit08c28c4e7fe814f39e742fd8cd617b42daa1534e (patch)
tree5aa758fb93a0475c27658dd4ded72c9cf7064acf /src/widgets/button.cpp
parentlimit the change to the relative moves only (diff)
downloadinkscape-08c28c4e7fe814f39e742fd8cd617b42daa1534e.tar.gz
inkscape-08c28c4e7fe814f39e742fd8cd617b42daa1534e.zip
Updating deprecated type calls.
(bzr r5617)
Diffstat (limited to 'src/widgets/button.cpp')
-rw-r--r--src/widgets/button.cpp33
1 files changed, 18 insertions, 15 deletions
diff --git a/src/widgets/button.cpp b/src/widgets/button.cpp
index 95d5859e8..6769fa389 100644
--- a/src/widgets/button.cpp
+++ b/src/widgets/button.cpp
@@ -56,22 +56,25 @@ SPActionEventVector button_event_vector = {
NULL
};
-GtkType
-sp_button_get_type (void)
+GType sp_button_get_type(void)
{
- static GtkType type = 0;
- if (!type) {
- GtkTypeInfo info = {
- "SPButton",
- sizeof (SPButton),
- sizeof (SPButtonClass),
- (GtkClassInitFunc) sp_button_class_init,
- (GtkObjectInitFunc) sp_button_init,
- NULL, NULL, NULL
- };
- type = gtk_type_unique (GTK_TYPE_TOGGLE_BUTTON, &info);
- }
- return type;
+ static GType type = 0;
+ if (!type) {
+ GTypeInfo info = {
+ sizeof(SPButtonClass),
+ 0, // base_init
+ 0, // base_finalize
+ (GClassInitFunc)sp_button_class_init,
+ 0, // class_finalize
+ 0, // class_data
+ sizeof(SPButton),
+ 0, // n_preallocs
+ (GInstanceInitFunc)sp_button_init,
+ 0 // value_table
+ };
+ type = g_type_register_static(GTK_TYPE_TOGGLE_BUTTON, "SPButton", &info, static_cast<GTypeFlags>(0));
+ }
+ return type;
}
static void