diff --git a/src/widgets/button.cpp b/src/widgets/button.cpp
index f9e854302424db73802be485664a39a258f6c1b7..6769fa389d9f1889e29f24e925053f0adb3d8f0f 100644 (file)
--- a/src/widgets/button.cpp
+++ b/src/widgets/button.cpp
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
}
static void
-sp_button_perform_action (SPButton *button, gpointer data)
+sp_button_perform_action (SPButton *button, gpointer /*data*/)
{
if (button->action) {
sp_action_perform (button->action, NULL);
}
static void
-sp_button_action_set_active (SPAction *action, unsigned int active, void *data)
+sp_button_action_set_active (SPAction */*action*/, unsigned int active, void *data)
{
SPButton *button;
button = (SPButton *) data;
@@ -269,13 +272,13 @@ sp_button_action_set_active (SPAction *action, unsigned int active, void *data)
}
static void
-sp_button_action_set_sensitive (SPAction *action, unsigned int sensitive, void *data)
+sp_button_action_set_sensitive (SPAction */*action*/, unsigned int sensitive, void *data)
{
gtk_widget_set_sensitive (GTK_WIDGET (data), sensitive);
}
static void
-sp_button_action_set_shortcut (SPAction *action, unsigned int shortcut, void *data)
+sp_button_action_set_shortcut (SPAction *action, unsigned int /*shortcut*/, void *data)
{
SPButton *button=SP_BUTTON (data);
if (button->tooltips) {