[PATCH] eel shutdown spam



I think since the cleanup of the shutdown procedure of the views the
eel_preferences_remove_callback() calls belong in finalize(), not
destroy(). destroy() is called twice via the dispose() methods in fm_
[list|icon]_view, causing the spam with

"(nautilus:9686): Eel-CRITICAL **: file eel-preferences.c: line 872
(preferences_entry_remove_callback): assertion `entry->callback_list !=
NULL' failed"

when quitting Nautilus.

Martin

Index: src/file-manager/fm-directory-view.c
===================================================================
RCS file: /cvs/gnome/nautilus/src/file-manager/fm-directory-view.c,v
retrieving revision 1.629
diff -u -p -w -r1.629 fm-directory-view.c
--- src/file-manager/fm-directory-view.c	22 Jul 2004 03:57:44 -0000	1.629
+++ src/file-manager/fm-directory-view.c	23 Jul 2004 06:26:35 -0000
@@ -1627,23 +1629,6 @@ fm_directory_view_destroy (GtkObject *ob
 		view->details->display_selection_idle_id = 0;
 	}
 
-	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_SHOW_HIDDEN_FILES,
-					 filtering_changed_callback, view);
-	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_SHOW_BACKUP_FILES,
-					 filtering_changed_callback, view);
-	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_CONFIRM_TRASH,
-					 schedule_update_menus_callback, view);
-	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_ENABLE_DELETE,
-					 schedule_update_menus_callback, view);
-	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_ICON_VIEW_CAPTIONS,
-					 text_attribute_names_changed_callback, view);
-	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_SHOW_IMAGE_FILE_THUMBNAILS,
-					 image_display_policy_changed_callback, view);
-	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_CLICK_POLICY,
-					 click_policy_changed_callback, view);
-	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_SORT_DIRECTORIES_FIRST,
-					 sort_directories_first_changed_callback, view);
-
 	if (view->details->model) {
 		nautilus_directory_unref (view->details->model);
 		view->details->model = NULL;
@@ -1667,6 +1652,23 @@ fm_directory_view_finalize (GObject *obj
 	FMDirectoryView *view;
 
 	view = FM_DIRECTORY_VIEW (object);
+
+	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_SHOW_HIDDEN_FILES,
+					 filtering_changed_callback, view);
+	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_SHOW_BACKUP_FILES,
+					 filtering_changed_callback, view);
+	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_CONFIRM_TRASH,
+					 schedule_update_menus_callback, view);
+	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_ENABLE_DELETE,
+					 schedule_update_menus_callback, view);
+	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_ICON_VIEW_CAPTIONS,
+					 text_attribute_names_changed_callback, view);
+	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_SHOW_IMAGE_FILE_THUMBNAILS,
+					 image_display_policy_changed_callback, view);
+	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_CLICK_POLICY,
+					 click_policy_changed_callback, view);
+	eel_preferences_remove_callback (NAUTILUS_PREFERENCES_SORT_DIRECTORIES_FIRST,
+					 sort_directories_first_changed_callback, view);
 
 	g_hash_table_destroy (view->details->non_ready_files);
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]