summaryrefslogtreecommitdiff
path: root/src/file-manager/fm-directory-view.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/file-manager/fm-directory-view.c')
-rw-r--r--src/file-manager/fm-directory-view.c32
1 files changed, 21 insertions, 11 deletions
diff --git a/src/file-manager/fm-directory-view.c b/src/file-manager/fm-directory-view.c
index bd75951e..a4119ec4 100644
--- a/src/file-manager/fm-directory-view.c
+++ b/src/file-manager/fm-directory-view.c
@@ -659,7 +659,7 @@ fm_directory_view_confirm_multiple (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;
}
@@ -2096,7 +2096,11 @@ real_unmerge_menus (FMDirectoryView *view)
}
static void
+#if GTK_CHECK_VERSION (3, 0, 0)
+fm_directory_view_destroy (GtkWidget *object)
+#else
fm_directory_view_destroy (GtkObject *object)
+#endif
{
FMDirectoryView *view;
GList *node, *next;
@@ -2157,7 +2161,11 @@ fm_directory_view_destroy (GtkObject *object)
view->details->directory_as_file = NULL;
}
+#if GTK_CHECK_VERSION (3, 0, 0)
+ EEL_CALL_PARENT (GTK_WIDGET_CLASS, destroy, (object));
+#else
EEL_CALL_PARENT (GTK_OBJECT_CLASS, destroy, (object));
+#endif
}
static void
@@ -2168,17 +2176,17 @@ fm_directory_view_finalize (GObject *object)
view = FM_DIRECTORY_VIEW (object);
g_signal_handlers_disconnect_by_func (caja_preferences,
- schedule_update_menus_callback, view);
+ schedule_update_menus_callback, view);
g_signal_handlers_disconnect_by_func (caja_icon_view_preferences,
- text_attribute_names_changed_callback, view);
+ text_attribute_names_changed_callback, view);
g_signal_handlers_disconnect_by_func (caja_preferences,
- image_display_policy_changed_callback, view);
+ image_display_policy_changed_callback, view);
g_signal_handlers_disconnect_by_func (caja_preferences,
- click_policy_changed_callback, view);
+ click_policy_changed_callback, view);
g_signal_handlers_disconnect_by_func (caja_preferences,
- sort_directories_first_changed_callback, view);
+ sort_directories_first_changed_callback, view);
g_signal_handlers_disconnect_by_func (mate_lockdown_preferences,
- schedule_update_menus, view);
+ schedule_update_menus, view);
unschedule_pop_up_location_context_menu (view);
if (view->details->location_popup_event != NULL) {
@@ -2738,7 +2746,7 @@ copy_move_done_callback (GHashTable *debuting_files, gpointer data)
* operate on. The ADD_FILE signal is registered as G_SIGNAL_RUN_LAST, so we
* must use connect_after.
*/
- g_signal_connect_data (GTK_OBJECT (directory_view),
+ g_signal_connect_data (directory_view,
"add_file",
G_CALLBACK (debuting_files_add_file_callback),
debuting_files_data,
@@ -10794,11 +10802,13 @@ fm_directory_view_class_init (FMDirectoryViewClass *klass)
widget_class = GTK_WIDGET_CLASS (klass);
scrolled_window_class = GTK_SCROLLED_WINDOW_CLASS (klass);
- G_OBJECT_CLASS (klass)->finalize = fm_directory_view_finalize;
G_OBJECT_CLASS (klass)->set_property = fm_directory_view_set_property;
-
+ G_OBJECT_CLASS (klass)->finalize = fm_directory_view_finalize;
+#if !GTK_CHECK_VERSION (3, 0, 0)
GTK_OBJECT_CLASS (klass)->destroy = fm_directory_view_destroy;
-
+#else
+ widget_class->destroy = fm_directory_view_destroy;
+#endif
widget_class->scroll_event = fm_directory_view_scroll_event;
widget_class->parent_set = fm_directory_view_parent_set;