summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libcaja-private/caja-autorun.c2
-rw-r--r--libcaja-private/caja-clipboard.c4
-rw-r--r--libcaja-private/caja-entry.c12
-rw-r--r--libcaja-private/caja-icon-container.c16
-rw-r--r--libcaja-private/caja-mime-actions.c6
-rw-r--r--libcaja-private/caja-mime-application-chooser.c10
-rw-r--r--libcaja-private/caja-open-with-dialog.c12
-rw-r--r--libcaja-private/caja-program-choosing.c2
8 files changed, 25 insertions, 39 deletions
diff --git a/libcaja-private/caja-autorun.c b/libcaja-private/caja-autorun.c
index 21f71eb8..89b8e63d 100644
--- a/libcaja-private/caja-autorun.c
+++ b/libcaja-private/caja-autorun.c
@@ -274,7 +274,7 @@ dialog_response_cb (GtkDialog *dialog,
}
static void
-dialog_destroy_cb (GtkObject *object,
+dialog_destroy_cb (GtkWidget *object,
CajaAutorunComboBoxData *data)
{
handle_dialog_closure (data);
diff --git a/libcaja-private/caja-clipboard.c b/libcaja-private/caja-clipboard.c
index b1614509..bc06675a 100644
--- a/libcaja-private/caja-clipboard.c
+++ b/libcaja-private/caja-clipboard.c
@@ -432,7 +432,7 @@ owner_change_callback (GtkClipboard *clipboard,
}
static void
-target_destroy_callback (GtkObject *object,
+target_destroy_callback (GtkWidget *object,
gpointer callback_data)
{
TargetCallbackData *target_data;
@@ -440,7 +440,7 @@ target_destroy_callback (GtkObject *object,
g_assert (callback_data != NULL);
target_data = callback_data;
- if (clipboard_items_are_merged_in (GTK_WIDGET(object)))
+ if (clipboard_items_are_merged_in (object))
{
merge_out_clipboard_menu_items (G_OBJECT (object), callback_data);
}
diff --git a/libcaja-private/caja-entry.c b/libcaja-private/caja-entry.c
index 863b1b4f..fb9ac38c 100644
--- a/libcaja-private/caja-entry.c
+++ b/libcaja-private/caja-entry.c
@@ -395,12 +395,10 @@ static void
caja_entry_class_init (CajaEntryClass *class)
{
GtkWidgetClass *widget_class;
- GtkObjectClass *object_class;
GObjectClass *gobject_class;
widget_class = GTK_WIDGET_CLASS (class);
gobject_class = G_OBJECT_CLASS (class);
- object_class = GTK_OBJECT_CLASS (class);
widget_class->button_press_event = caja_entry_button_press;
widget_class->button_release_event = caja_entry_button_release;
@@ -413,19 +411,17 @@ caja_entry_class_init (CajaEntryClass *class)
/* Set up signals */
signals[USER_CHANGED] = g_signal_new
("user_changed",
- G_TYPE_FROM_CLASS (object_class),
+ G_TYPE_FROM_CLASS (class),
G_SIGNAL_RUN_LAST,
- G_STRUCT_OFFSET (CajaEntryClass,
- user_changed),
+ G_STRUCT_OFFSET (CajaEntryClass, user_changed),
NULL, NULL,
g_cclosure_marshal_VOID__VOID,
G_TYPE_NONE, 0);
signals[SELECTION_CHANGED] = g_signal_new
("selection_changed",
- G_TYPE_FROM_CLASS (object_class),
+ G_TYPE_FROM_CLASS (class),
G_SIGNAL_RUN_LAST,
- G_STRUCT_OFFSET (CajaEntryClass,
- selection_changed),
+ G_STRUCT_OFFSET (CajaEntryClass, selection_changed),
NULL, NULL,
g_cclosure_marshal_VOID__VOID,
G_TYPE_NONE, 0);
diff --git a/libcaja-private/caja-icon-container.c b/libcaja-private/caja-icon-container.c
index f9b01311..0f6898c9 100644
--- a/libcaja-private/caja-icon-container.c
+++ b/libcaja-private/caja-icon-container.c
@@ -4379,10 +4379,12 @@ select_previous_or_next_icon (CajaIconContainer *container,
}
#endif
-/* GtkObject methods. */
-
static void
+#if GTK_CHECK_VERSION(3, 0, 0)
+destroy (GtkWidget *object)
+#else
destroy (GtkObject *object)
+#endif
{
CajaIconContainer *container;
@@ -4439,8 +4441,11 @@ destroy (GtkObject *object)
}
}
-
+#if GTK_CHECK_VERSION(3, 0, 0)
+ GTK_WIDGET_CLASS (caja_icon_container_parent_class)->destroy (object);
+#else
GTK_OBJECT_CLASS (caja_icon_container_parent_class)->destroy (object);
+#endif
}
static void
@@ -6213,7 +6218,12 @@ caja_icon_container_class_init (CajaIconContainerClass *class)
G_OBJECT_CLASS (class)->constructor = caja_icon_container_constructor;
G_OBJECT_CLASS (class)->finalize = finalize;
+
+#if GTK_CHECK_VERSION(3, 0, 0)
+ GTK_WIDGET_CLASS (class)->destroy = destroy;
+#else
GTK_OBJECT_CLASS (class)->destroy = destroy;
+#endif
/* Signals. */
diff --git a/libcaja-private/caja-mime-actions.c b/libcaja-private/caja-mime-actions.c
index a4dc8c97..794c84b0 100644
--- a/libcaja-private/caja-mime-actions.c
+++ b/libcaja-private/caja-mime-actions.c
@@ -793,7 +793,7 @@ report_broken_symbolic_link (GtkWindow *parent_window, CajaFile *file)
*/
response = gtk_dialog_run (dialog);
- gtk_object_destroy (GTK_OBJECT (dialog));
+ gtk_widget_destroy (GTK_WIDGET (dialog));
if (response == GTK_RESPONSE_YES)
{
@@ -860,7 +860,7 @@ get_executable_text_file_action (GtkWindow *parent_window, CajaFile *file)
g_free (detail);
response = gtk_dialog_run (dialog);
- gtk_object_destroy (GTK_OBJECT (dialog));
+ gtk_widget_destroy (GTK_WIDGET (dialog));
switch (response)
{
@@ -1223,7 +1223,7 @@ confirm_multiple_windows (GtkWindow *parent_window,
g_free (detail);
response = gtk_dialog_run (dialog);
- gtk_object_destroy (GTK_OBJECT (dialog));
+ gtk_widget_destroy (GTK_WIDGET (dialog));
return response == GTK_RESPONSE_YES;
}
diff --git a/libcaja-private/caja-mime-application-chooser.c b/libcaja-private/caja-mime-application-chooser.c
index 3f458dba..32767f38 100644
--- a/libcaja-private/caja-mime-application-chooser.c
+++ b/libcaja-private/caja-mime-application-chooser.c
@@ -108,22 +108,12 @@ caja_mime_application_chooser_finalize (GObject *object)
}
static void
-caja_mime_application_chooser_destroy (GtkObject *object)
-{
- GTK_OBJECT_CLASS (caja_mime_application_chooser_parent_class)->destroy (object);
-}
-
-static void
caja_mime_application_chooser_class_init (CajaMimeApplicationChooserClass *class)
{
GObjectClass *gobject_class;
- GtkObjectClass *object_class;
gobject_class = G_OBJECT_CLASS (class);
gobject_class->finalize = caja_mime_application_chooser_finalize;
-
- object_class = GTK_OBJECT_CLASS (class);
- object_class->destroy = caja_mime_application_chooser_destroy;
}
static void
diff --git a/libcaja-private/caja-open-with-dialog.c b/libcaja-private/caja-open-with-dialog.c
index dcd601bc..93e376c9 100644
--- a/libcaja-private/caja-open-with-dialog.c
+++ b/libcaja-private/caja-open-with-dialog.c
@@ -120,12 +120,6 @@ caja_open_with_dialog_finalize (GObject *object)
G_OBJECT_CLASS (caja_open_with_dialog_parent_class)->finalize (object);
}
-static void
-caja_open_with_dialog_destroy (GtkObject *object)
-{
- GTK_OBJECT_CLASS (caja_open_with_dialog_parent_class)->destroy (object);
-}
-
/* An application is valid if:
*
* 1) The file exists
@@ -397,17 +391,13 @@ static void
caja_open_with_dialog_class_init (CajaOpenWithDialogClass *class)
{
GObjectClass *gobject_class;
- GtkObjectClass *object_class;
gobject_class = G_OBJECT_CLASS (class);
gobject_class->finalize = caja_open_with_dialog_finalize;
- object_class = GTK_OBJECT_CLASS (class);
- object_class->destroy = caja_open_with_dialog_destroy;
-
signals[APPLICATION_SELECTED] =
g_signal_new ("application_selected",
- G_TYPE_FROM_CLASS (object_class),
+ G_TYPE_FROM_CLASS (class),
G_SIGNAL_RUN_LAST,
G_STRUCT_OFFSET (CajaOpenWithDialogClass,
application_selected),
diff --git a/libcaja-private/caja-program-choosing.c b/libcaja-private/caja-program-choosing.c
index a31746ec..56d6e8eb 100644
--- a/libcaja-private/caja-program-choosing.c
+++ b/libcaja-private/caja-program-choosing.c
@@ -98,7 +98,7 @@ application_cannot_open_location (GAppInfo *application,
GTK_STOCK_CANCEL,
parent_window);
response = gtk_dialog_run (message_dialog);
- gtk_object_destroy (GTK_OBJECT (message_dialog));
+ gtk_widget_destroy (GTK_WIDGET (message_dialog));
if (response == GTK_RESPONSE_YES)
{