summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDarin Adler <darin@src.gnome.org>2002-01-19 00:06:14 +0000
committerDarin Adler <darin@src.gnome.org>2002-01-19 00:06:14 +0000
commit074ed7a01a2db2e82771eee7412dbbf3a115630f (patch)
treea88c6f49863a8e37ef0ebd3f67ab57cb1453ad7c
parent5a837d8ac19aa878dae1e5af9d7969869859c58a (diff)
downloadnautilus-074ed7a01a2db2e82771eee7412dbbf3a115630f.tar.gz
Remove nautilus-launch-icon.png.
* Makefile.am: Remove nautilus-launch-icon.png. * components/hardware/nautilus-hardware-view.c: (setup_form_title), (setup_overview_form): Port from EelImage to GtkImage. * components/music/nautilus-music-view.c: Remove unused include. * src/nautilus-theme-selector.c: Remove unused includes. * libnautilus-private/nautilus-bonobo-extensions.c: (bonobo_activation_activation_callback): Add warning message so we get to see the error from bonobo-activation. * libnautilus-private/nautilus-directory-metafile.c: (get_factory): * libnautilus-private/nautilus-icon-factory.c: (get_icon_factory), (load_icon_for_scaling), (embed_text): * libnautilus-private/nautilus-metafile-factory.c: (nautilus_metafile_factory_get_instance): * libnautilus-private/nautilus-theme.c: (nautilus_theme_get_theme_data_from_theme): * libnautilus-private/nautilus-trash-monitor.c: (nautilus_trash_monitor_get): * libnautilus-private/nautilus-volume-monitor.c: (nautilus_volume_monitor_get): * src/file-manager/nautilus-indexing-info.c: (show_indexing_info_dialog): * src/nautilus-preferences-dialog.c: (global_preferences_get_dialog): * src/nautilus-window.c: (nautilus_window_class_init), (add_to_history_list): Use eel_debug_call_at_shutdown instead of g_atexit. * libnautilus-private/nautilus-file.c: (nautilus_file_get_display_name): Add G_BROKEN_FILENAMES support. * libnautilus-private/nautilus-global-preferences.c: (nautilus_global_preferences_init): Remove eel_smooth_widget code. * libnautilus/Makefile.am: Add missing ORBIT_IDL dependency. * libnautilus/nautilus-view-standard-main.c: (nautilus_view_standard_main_multi): Remove bonobo_ui_debug_shutdown for now. It does us no good unless we also do eel_debug_shut_down, but libnautilus can't depend on eel. * nautilus-launch-icon.png: Remove. * src/file-manager/fm-properties-window.c: (update_properties_window_icon), (fm_properties_window_drag_data_received), (create_image_widget_for_file): Port from EelImage to GtkImage. * src/nautilus-component-adapter-factory.c: (nautilus_component_adapter_factory_get): Use eel_debug_call_at_shutdown instead of g_atexit. (nautilus_component_adapter_factory_create_adapter): Look at exceptions before looking at return values from CORBA calls. * src/nautilus-main.c: (main): Add a call to eel_debug_shut_down. * src/nautilus-property-browser.c: (nautilus_property_browser_init), (element_clicked_callback), (nautilus_property_browser_update_contents): Port from EelViewport to GtkViewport. * src/nautilus-search-bar-criterion.c: (nautilus_search_bar_criterion_destroy), (nautilus_search_bar_criterion_new_from_values): Fix for change that made NautilusSignaller no longer a GtkObject. * src/nautilus-sidebar-title.c: (nautilus_sidebar_title_init), (update_icon), (add_emblem): Port from EelImage to GtkImage. * src/nautilus-signaller.h: * src/nautilus-signaller.c: (nautilus_signaller_get_current): Use eel_debug_call_at_shutdown instead of g_atexit. (nautilus_signaller_instance_init), (nautilus_signaller_class_init): Change to GObject, not GtkObject. * src/nautilus-window-menus.c: (get_bookmark_list): Use eel_debug_call_at_shutdown instead of g_atexit. (nautilus_window_initialize_go_menu): Fix for change that made NautilusSignaller no longer a GtkObject. * test/test-nautilus-preferences-change.c: Remove unused include. * test/test-nautilus-preferences-display.c: Remove unused includes. * test/test-nautilus-wrap-table.c: Remove unused includes. * test/test.c: Remove unused function. * test/test.h: Remove unused function.
-rw-r--r--ChangeLog91
-rw-r--r--Makefile.am4
-rw-r--r--components/hardware/nautilus-hardware-view.c9
-rw-r--r--components/music/nautilus-music-view.c1
-rw-r--r--libnautilus-private/nautilus-bonobo-extensions.c5
-rw-r--r--libnautilus-private/nautilus-directory-metafile.c3
-rw-r--r--libnautilus-private/nautilus-directory.c14
-rw-r--r--libnautilus-private/nautilus-file.c15
-rw-r--r--libnautilus-private/nautilus-global-preferences.c21
-rw-r--r--libnautilus-private/nautilus-icon-factory.c7
-rw-r--r--libnautilus-private/nautilus-metafile-factory.c3
-rw-r--r--libnautilus-private/nautilus-theme.c5
-rw-r--r--libnautilus-private/nautilus-trash-monitor.c3
-rw-r--r--libnautilus-private/nautilus-volume-monitor.c3
-rw-r--r--libnautilus/Makefile.am4
-rw-r--r--libnautilus/nautilus-view-standard-main.c1
-rw-r--r--nautilus-launch-icon.pngbin4472 -> 0 bytes
-rw-r--r--src/file-manager/fm-properties-window.c17
-rw-r--r--src/file-manager/nautilus-indexing-info.c2
-rw-r--r--src/nautilus-component-adapter-factory.c40
-rw-r--r--src/nautilus-main.c2
-rw-r--r--src/nautilus-navigation-window-menus.c12
-rw-r--r--src/nautilus-navigation-window.c5
-rw-r--r--src/nautilus-object-window.c5
-rw-r--r--src/nautilus-preferences-dialog.c3
-rw-r--r--src/nautilus-property-browser.c21
-rw-r--r--src/nautilus-search-bar-criterion.c35
-rw-r--r--src/nautilus-sidebar-title.c9
-rw-r--r--src/nautilus-signaller.c73
-rw-r--r--src/nautilus-signaller.h4
-rw-r--r--src/nautilus-spatial-window.c5
-rw-r--r--src/nautilus-theme-selector.c3
-rw-r--r--src/nautilus-window-menus.c12
-rw-r--r--src/nautilus-window.c5
-rw-r--r--test/test-nautilus-preferences-change.c2
-rw-r--r--test/test-nautilus-preferences-display.c2
-rw-r--r--test/test-nautilus-wrap-table.c1
-rw-r--r--test/test.c27
-rw-r--r--test/test.h5
39 files changed, 246 insertions, 233 deletions
diff --git a/ChangeLog b/ChangeLog
index 2eb4f4fda..d2c41cf1a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,94 @@
+2002-01-18 Darin Adler <darin@bentspoon.com>
+
+ * Makefile.am: Remove nautilus-launch-icon.png.
+
+ * components/hardware/nautilus-hardware-view.c: (setup_form_title),
+ (setup_overview_form): Port from EelImage to GtkImage.
+
+ * components/music/nautilus-music-view.c: Remove unused include.
+ * src/nautilus-theme-selector.c: Remove unused includes.
+
+ * libnautilus-private/nautilus-bonobo-extensions.c:
+ (bonobo_activation_activation_callback): Add warning message so we
+ get to see the error from bonobo-activation.
+
+ * libnautilus-private/nautilus-directory-metafile.c: (get_factory):
+ * libnautilus-private/nautilus-icon-factory.c: (get_icon_factory),
+ (load_icon_for_scaling), (embed_text):
+ * libnautilus-private/nautilus-metafile-factory.c:
+ (nautilus_metafile_factory_get_instance):
+ * libnautilus-private/nautilus-theme.c:
+ (nautilus_theme_get_theme_data_from_theme):
+ * libnautilus-private/nautilus-trash-monitor.c:
+ (nautilus_trash_monitor_get):
+ * libnautilus-private/nautilus-volume-monitor.c:
+ (nautilus_volume_monitor_get):
+ * src/file-manager/nautilus-indexing-info.c:
+ (show_indexing_info_dialog):
+ * src/nautilus-preferences-dialog.c:
+ (global_preferences_get_dialog):
+ * src/nautilus-window.c: (nautilus_window_class_init),
+ (add_to_history_list):
+ Use eel_debug_call_at_shutdown instead of g_atexit.
+
+ * libnautilus-private/nautilus-file.c:
+ (nautilus_file_get_display_name): Add G_BROKEN_FILENAMES support.
+
+ * libnautilus-private/nautilus-global-preferences.c:
+ (nautilus_global_preferences_init): Remove eel_smooth_widget code.
+
+ * libnautilus/Makefile.am: Add missing ORBIT_IDL dependency.
+
+ * libnautilus/nautilus-view-standard-main.c:
+ (nautilus_view_standard_main_multi): Remove
+ bonobo_ui_debug_shutdown for now. It does us no good unless we
+ also do eel_debug_shut_down, but libnautilus can't depend on eel.
+
+ * nautilus-launch-icon.png: Remove.
+
+ * src/file-manager/fm-properties-window.c:
+ (update_properties_window_icon),
+ (fm_properties_window_drag_data_received),
+ (create_image_widget_for_file): Port from EelImage to GtkImage.
+
+ * src/nautilus-component-adapter-factory.c:
+ (nautilus_component_adapter_factory_get): Use
+ eel_debug_call_at_shutdown instead of g_atexit.
+ (nautilus_component_adapter_factory_create_adapter): Look at
+ exceptions before looking at return values from CORBA calls.
+
+ * src/nautilus-main.c: (main): Add a call to eel_debug_shut_down.
+
+ * src/nautilus-property-browser.c:
+ (nautilus_property_browser_init), (element_clicked_callback),
+ (nautilus_property_browser_update_contents): Port from EelViewport
+ to GtkViewport.
+
+ * src/nautilus-search-bar-criterion.c:
+ (nautilus_search_bar_criterion_destroy),
+ (nautilus_search_bar_criterion_new_from_values): Fix for change
+ that made NautilusSignaller no longer a GtkObject.
+
+ * src/nautilus-sidebar-title.c: (nautilus_sidebar_title_init),
+ (update_icon), (add_emblem): Port from EelImage to GtkImage.
+
+ * src/nautilus-signaller.h:
+ * src/nautilus-signaller.c: (nautilus_signaller_get_current): Use
+ eel_debug_call_at_shutdown instead of g_atexit.
+ (nautilus_signaller_instance_init),
+ (nautilus_signaller_class_init): Change to GObject, not GtkObject.
+
+ * src/nautilus-window-menus.c: (get_bookmark_list): Use
+ eel_debug_call_at_shutdown instead of g_atexit.
+ (nautilus_window_initialize_go_menu): Fix for change that made
+ NautilusSignaller no longer a GtkObject.
+
+ * test/test-nautilus-preferences-change.c: Remove unused include.
+ * test/test-nautilus-preferences-display.c: Remove unused includes.
+ * test/test-nautilus-wrap-table.c: Remove unused includes.
+ * test/test.c: Remove unused function.
+ * test/test.h: Remove unused function.
+
2002-01-18 Michael Meeks <michael@ximian.com>
* libnautilus-private/nautilus-directory-background.c
diff --git a/Makefile.am b/Makefile.am
index 4a21af318..7df213b93 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -30,7 +30,6 @@ EXTRA_DIST= \
nautilus.spec.in \
nautilus.desktop \
nautilus.desktop.in \
- nautilus-launch-icon.png \
gnome-starthere-96.png \
gnome-starthere.png \
ChangeLog-20000414 \
@@ -47,8 +46,7 @@ EXTRA_DIST= \
$(NULL)
appicondir = $(datadir)/pixmaps
-appicon_DATA = nautilus-launch-icon.png \
- gnome-starthere-96.png \
+appicon_DATA = gnome-starthere-96.png \
gnome-starthere.png
Applicationsdir = $(datadir)/applications
diff --git a/components/hardware/nautilus-hardware-view.c b/components/hardware/nautilus-hardware-view.c
index fc0603085..d26685818 100644
--- a/components/hardware/nautilus-hardware-view.c
+++ b/components/hardware/nautilus-hardware-view.c
@@ -41,7 +41,6 @@
#include <eel/eel-glib-extensions.h>
#include <eel/eel-gtk-extensions.h>
#include <eel/eel-gtk-macros.h>
-#include <eel/eel-image.h>
#include <libnautilus-private/nautilus-metadata.h>
#include <eel/eel-string.h>
#include <libnautilus/libnautilus.h>
@@ -447,7 +446,7 @@ setup_form_title (NautilusHardwareView *view,
if (image_name != NULL) {
file_name = gnome_pixmap_file (image_name);
if (file_name != NULL) {
- temp_widget = eel_image_new (file_name);
+ temp_widget = gtk_image_new_from_file (file_name);
gtk_box_pack_start (GTK_BOX(temp_container), temp_widget, 0, 0, 8);
gtk_widget_show (temp_widget);
g_free (file_name);
@@ -531,7 +530,7 @@ setup_overview_form (NautilusHardwareView *view)
gtk_widget_show (temp_box);
file_name = nautilus_pixmap_file ("cpu.png");
- temp_widget = eel_image_new (file_name);
+ temp_widget = gtk_image_new_from_file (file_name);
gtk_box_pack_start (GTK_BOX(temp_box), temp_widget, 0, 0, 0);
gtk_widget_show (temp_widget);
g_free (file_name);
@@ -551,7 +550,7 @@ setup_overview_form (NautilusHardwareView *view)
gtk_widget_show (temp_box);
file_name = nautilus_pixmap_file ("memory_chip.gif");
- temp_widget = eel_image_new (file_name);
+ temp_widget = gtk_image_new_from_file (file_name);
gtk_box_pack_start(GTK_BOX(temp_box), temp_widget, 0, 0, 0);
gtk_widget_show(temp_widget);
g_free (file_name);
@@ -589,7 +588,7 @@ setup_overview_form (NautilusHardwareView *view)
file_name = nautilus_pixmap_file ("i-harddisk.png");
}
- pixmap_widget = eel_image_new (file_name);
+ pixmap_widget = gtk_image_new_from_file (file_name);
gtk_box_pack_start (GTK_BOX(temp_box), pixmap_widget, 0, 0, 0);
gtk_widget_show(pixmap_widget);
g_free(file_name);
diff --git a/components/music/nautilus-music-view.c b/components/music/nautilus-music-view.c
index df1e13561..73ef4e493 100644
--- a/components/music/nautilus-music-view.c
+++ b/components/music/nautilus-music-view.c
@@ -38,7 +38,6 @@
#include <eel/eel-glib-extensions.h>
#include <eel/eel-gtk-extensions.h>
#include <eel/eel-gtk-macros.h>
-#include <eel/eel-image.h>
#include <eel/eel-preferences.h>
#include <eel/eel-stock-dialogs.h>
#include <eel/eel-string.h>
diff --git a/libnautilus-private/nautilus-bonobo-extensions.c b/libnautilus-private/nautilus-bonobo-extensions.c
index 19515a68b..3b921852a 100644
--- a/libnautilus-private/nautilus-bonobo-extensions.c
+++ b/libnautilus-private/nautilus-bonobo-extensions.c
@@ -567,6 +567,9 @@ bonobo_activation_activation_callback (Bonobo_Unknown activated_object,
handle = (NautilusBonoboActivationHandle *) callback_data;
+ if (activated_object == NULL)
+ g_warning ("activation failed: %s", error_reason);
+
handle->activated_object = activated_object;
if (handle->cancel) {
@@ -632,7 +635,7 @@ nautilus_bonobo_activate_cancel (NautilusBonoboActivationHandle *handle)
activation_handle_done (handle);
if (handle->idle_id == 0) {
- /* no way to cancel the OAF part, so we just set a flag */
+ /* no way to cancel the underlying bonobo-activation call, so we just set a flag */
handle->cancel = TRUE;
} else {
gtk_idle_remove (handle->idle_id);
diff --git a/libnautilus-private/nautilus-directory-metafile.c b/libnautilus-private/nautilus-directory-metafile.c
index 11429f83d..994dc7a4e 100644
--- a/libnautilus-private/nautilus-directory-metafile.c
+++ b/libnautilus-private/nautilus-directory-metafile.c
@@ -30,6 +30,7 @@
#include "nautilus-metafile-factory.h"
#include "nautilus-directory-metafile-monitor.h"
#include "nautilus-metafile-server.h"
+#include <eel/eel-debug.h>
#include <eel/eel-string.h>
#include <bonobo-activation/bonobo-activation.h>
#include <stdio.h>
@@ -111,7 +112,7 @@ get_factory (void)
factory = bonobo_object_dup_ref (bonobo_object_corba_objref (BONOBO_OBJECT (instance)), NULL);
bonobo_object_unref (BONOBO_OBJECT (instance));
}
- g_atexit (free_factory);
+ eel_debug_call_at_shutdown (free_factory);
}
return factory;
diff --git a/libnautilus-private/nautilus-directory.c b/libnautilus-private/nautilus-directory.c
index 405c7433d..6ea3a5de5 100644
--- a/libnautilus-private/nautilus-directory.c
+++ b/libnautilus-private/nautilus-directory.c
@@ -63,7 +63,6 @@ static guint signals[LAST_SIGNAL];
static GHashTable *directories;
static void nautilus_directory_finalize (GObject *object);
-static void nautilus_directory_dispose (GObject *object);
static void nautilus_directory_init (gpointer object,
gpointer klass);
static void nautilus_directory_class_init (NautilusDirectoryClass *klass);
@@ -84,7 +83,6 @@ nautilus_directory_class_init (NautilusDirectoryClass *klass)
object_class = G_OBJECT_CLASS (klass);
object_class->finalize = nautilus_directory_finalize;
- object_class->dispose = nautilus_directory_dispose;
signals[FILES_ADDED] =
g_signal_new ("files_added",
@@ -161,7 +159,7 @@ nautilus_directory_unref (NautilusDirectory *directory)
}
static void
-nautilus_directory_dispose (GObject *object)
+nautilus_directory_finalize (GObject *object)
{
NautilusDirectory *directory;
@@ -206,16 +204,6 @@ nautilus_directory_dispose (GObject *object)
directory->details->vfs_uri = NULL;
}
- EEL_CALL_PARENT (G_OBJECT_CLASS, dispose, (object));
-}
-
-static void
-nautilus_directory_finalize (GObject *object)
-{
- NautilusDirectory *directory;
-
- directory = NAUTILUS_DIRECTORY (object);
-
g_assert (directory->details->file_list == NULL);
g_hash_table_destroy (directory->details->file_hash);
diff --git a/libnautilus-private/nautilus-file.c b/libnautilus-private/nautilus-file.c
index 3a254f3bf..d4571245a 100644
--- a/libnautilus-private/nautilus-file.c
+++ b/libnautilus-private/nautilus-file.c
@@ -1070,6 +1070,7 @@ nautilus_file_rename (NautilusFile *file,
/* Do the renaming. */
partial_file_info = gnome_vfs_file_info_new ();
+ /* FIXME: Handle G_BROKEN_FILENAMES here? */
partial_file_info->name = g_strdup (new_name);
vfs_uri = nautilus_file_get_gnome_vfs_uri (file);
gnome_vfs_async_set_file_info (&op->handle,
@@ -2300,7 +2301,7 @@ make_valid_utf8 (char *name)
char *
nautilus_file_get_display_name (NautilusFile *file)
{
- char *name;
+ char *name, *utf8_name;
if (file == NULL) {
return NULL;
@@ -2318,6 +2319,18 @@ nautilus_file_get_display_name (NautilusFile *file)
* but convenient for people who just want to display it.
*/
name = g_strdup (file->details->relative_uri);
+ } else {
+ /* Support the G_BROKEN_FILENAMES feature of
+ * glib by using g_filename_to_utf8 to convert
+ * local filenames to UTF-8.
+ */
+ if (g_getenv ("G_BROKEN_FILENAMES") != NULL && nautilus_file_is_local (file)) {
+ utf8_name = g_filename_to_utf8 (name, -1, NULL, NULL, NULL);
+ if (utf8_name != NULL) {
+ name = utf8_name;
+ g_free (name);
+ }
+ }
}
}
diff --git a/libnautilus-private/nautilus-global-preferences.c b/libnautilus-private/nautilus-global-preferences.c
index 953f06771..87e2caaef 100644
--- a/libnautilus-private/nautilus-global-preferences.c
+++ b/libnautilus-private/nautilus-global-preferences.c
@@ -33,7 +33,6 @@
#include <eel/eel-enumeration.h>
#include <eel/eel-glib-extensions.h>
#include <eel/eel-gtk-extensions.h>
-#include <eel/eel-smooth-widget.h>
#include <eel/eel-stock-dialogs.h>
#include <eel/eel-string.h>
#include <libgnome/gnome-i18n.h>
@@ -731,17 +730,6 @@ default_home_location_callback (void)
* Public functions
*/
-/* Let the smooth widget machinery know about smoothness changes */
-static void
-smooth_graphics_mode_changed_callback (gpointer callback_data)
-{
- gboolean is_smooth;
-
- is_smooth = eel_preferences_get_boolean (NAUTILUS_PREFERENCES_SMOOTH_GRAPHICS_MODE);
-
- eel_smooth_widget_global_set_is_smooth (is_smooth);
-}
-
static void
set_default_folder_viewer_in_gnome_vfs (const char *iid)
{
@@ -843,10 +831,6 @@ nautilus_global_preferences_init (void)
eel_preferences_monitor_directory (SYSTEM_GNOME_VFS_PATH);
/* Set up storage for values accessed in this file */
- eel_preferences_add_callback (NAUTILUS_PREFERENCES_SMOOTH_GRAPHICS_MODE,
- smooth_graphics_mode_changed_callback,
- NULL);
-
eel_preferences_add_callback (NAUTILUS_PREFERENCES_DEFAULT_FOLDER_VIEWER,
default_folder_viewer_changed_callback,
NULL);
@@ -855,11 +839,6 @@ nautilus_global_preferences_init (void)
default_icon_view_sort_order_or_manual_layout_changed_callback,
NULL);
- /* Keep track of smooth graphics mode changes in order to notify the smooth
- * widget machinery.
- */
- smooth_graphics_mode_changed_callback (NULL);
-
/* Preload everything in a big batch */
eel_gconf_preload_cache ("/apps/nautilus/preferences",
GCONF_CLIENT_PRELOAD_ONELEVEL);
diff --git a/libnautilus-private/nautilus-icon-factory.c b/libnautilus-private/nautilus-icon-factory.c
index 9b8ba647f..a328c640f 100644
--- a/libnautilus-private/nautilus-icon-factory.c
+++ b/libnautilus-private/nautilus-icon-factory.c
@@ -39,6 +39,7 @@
#include "nautilus-theme.h"
#include "nautilus-thumbnails.h"
#include "nautilus-trash-monitor.h"
+#include <eel/eel-debug.h>
#include <eel/eel-gdk-extensions.h>
#include <eel/eel-gdk-pixbuf-extensions.h>
#include <eel/eel-gdk-pixbuf-extensions.h>
@@ -289,7 +290,7 @@ get_icon_factory (void)
G_CALLBACK (mime_type_data_changed_callback),
NULL);
- g_atexit (destroy_icon_factory);
+ eel_debug_call_at_shutdown (destroy_icon_factory);
}
return global_icon_factory;
}
@@ -1685,7 +1686,7 @@ load_icon_for_scaling (NautilusScalableIcon *scalable_icon,
NULL);
fallback_icon = cache_icon_new (pixbuf, FALSE, FALSE, NULL);
fallback_icon->is_fallback = TRUE;
- g_atexit (destroy_fallback_icon);
+ eel_debug_call_at_shutdown (destroy_fallback_icon);
}
*actual_size_result = NAUTILUS_ICON_SIZE_STANDARD;
@@ -2259,7 +2260,7 @@ embed_text (GdkPixbuf *pixbuf_without_text,
GINT_TO_POINTER (TRUE));
embedded_text_font_changed_callback (GINT_TO_POINTER (FALSE));
- g_atexit (embedded_text_font_free);
+ eel_debug_call_at_shutdown (embedded_text_font_free);
}
g_return_val_if_fail (EEL_IS_SCALABLE_FONT (embedded_text_font), NULL);
diff --git a/libnautilus-private/nautilus-metafile-factory.c b/libnautilus-private/nautilus-metafile-factory.c
index 610103ae0..690424bd9 100644
--- a/libnautilus-private/nautilus-metafile-factory.c
+++ b/libnautilus-private/nautilus-metafile-factory.c
@@ -24,6 +24,7 @@
#include "nautilus-metafile-factory.h"
#include "nautilus-metafile.h"
+#include <eel/eel-debug.h>
#include <eel/eel-gtk-macros.h>
#include "nautilus-bonobo-extensions.h"
@@ -74,7 +75,7 @@ nautilus_metafile_factory_get_instance (void)
{
if (the_factory == NULL) {
the_factory = nautilus_metafile_factory_new ();
- g_atexit (free_factory_instance);
+ eel_debug_call_at_shutdown (free_factory_instance);
}
bonobo_object_ref (BONOBO_OBJECT (the_factory));
diff --git a/libnautilus-private/nautilus-theme.c b/libnautilus-private/nautilus-theme.c
index 7136187f7..6f1b193db 100644
--- a/libnautilus-private/nautilus-theme.c
+++ b/libnautilus-private/nautilus-theme.c
@@ -29,6 +29,7 @@
#include "nautilus-file.h"
#include "nautilus-global-preferences.h"
#include "nautilus-metadata.h"
+#include <eel/eel-debug.h>
#include <eel/eel-gdk-pixbuf-extensions.h>
#include <eel/eel-glib-extensions.h>
#include <eel/eel-string-list.h>
@@ -171,7 +172,7 @@ nautilus_theme_get_theme_data_from_theme (const char *resource_name, const char
} else {
/* release the old saved data, since the theme changed */
if (!did_set_up_free_last_theme) {
- g_atexit (free_last_theme);
+ eel_debug_call_at_shutdown (free_last_theme);
did_set_up_free_last_theme = TRUE;
}
free_last_theme ();
@@ -197,7 +198,7 @@ nautilus_theme_get_theme_data_from_theme (const char *resource_name, const char
if (theme_data == NULL) {
if (default_theme_document == NULL) {
default_theme_document = load_theme_document ("default");
- g_atexit (free_default_theme);
+ eel_debug_call_at_shutdown (free_default_theme);
}
resource_node = eel_xml_get_child_by_name (xmlDocGetRootElement (default_theme_document), resource_name);
diff --git a/libnautilus-private/nautilus-trash-monitor.c b/libnautilus-private/nautilus-trash-monitor.c
index a43c84f82..2ce804423 100644
--- a/libnautilus-private/nautilus-trash-monitor.c
+++ b/libnautilus-private/nautilus-trash-monitor.c
@@ -30,6 +30,7 @@
#include "nautilus-directory.h"
#include "nautilus-file-attributes.h"
#include "nautilus-trash-directory.h"
+#include <eel/eel-debug.h>
#include <eel/eel-gtk-macros.h>
#include <eel/eel-vfs-extensions.h>
#include <gtk/gtksignal.h>
@@ -193,7 +194,7 @@ nautilus_trash_monitor_get (void)
(g_object_new (NAUTILUS_TYPE_TRASH_MONITOR, NULL));
g_object_ref (nautilus_trash_monitor);
gtk_object_sink (GTK_OBJECT (nautilus_trash_monitor));
- g_atexit (unref_trash_monitor);
+ eel_debug_call_at_shutdown (unref_trash_monitor);
/* make sure we get signalled when trash directories get added */
nautilus_trash_directory_finish_initializing
diff --git a/libnautilus-private/nautilus-volume-monitor.c b/libnautilus-private/nautilus-volume-monitor.c
index 639a39124..6a5e5661d 100644
--- a/libnautilus-private/nautilus-volume-monitor.c
+++ b/libnautilus-private/nautilus-volume-monitor.c
@@ -31,6 +31,7 @@
#include "nautilus-file-utilities.h"
#include "nautilus-iso9660.h"
#include "nautilus-volume-monitor.h"
+#include <eel/eel-debug.h>
#include <eel/eel-glib-extensions.h>
#include <eel/eel-gnome-extensions.h>
#include <eel/eel-gtk-extensions.h>
@@ -395,7 +396,7 @@ nautilus_volume_monitor_get (void)
NULL));
g_object_ref (global_volume_monitor);
gtk_object_sink (GTK_OBJECT (global_volume_monitor));
- g_atexit (unref_global_volume_monitor);
+ eel_debug_call_at_shutdown (unref_global_volume_monitor);
}
return global_volume_monitor;
diff --git a/libnautilus/Makefile.am b/libnautilus/Makefile.am
index 4eccbe627..41503e93c 100644
--- a/libnautilus/Makefile.am
+++ b/libnautilus/Makefile.am
@@ -55,12 +55,12 @@ libnautilus_la_SOURCES= \
$(NULL)
$(nautilus_view_component_idl_sources): nautilus_view_component_idl_stamp
-nautilus_view_component_idl_stamp: nautilus-view-component.idl
+nautilus_view_component_idl_stamp: nautilus-view-component.idl $(ORBIT_IDL)
$(ORBIT_IDL) $(LIBNAUTILUS_IDL_INCLUDES) --define=__nautilus_view_component_COMPILATION $<
touch $@
$(nautilus_distributed_undo_idl_sources): nautilus_distributed_undo_idl_stamp
-nautilus_distributed_undo_idl_stamp: nautilus-distributed-undo.idl
+nautilus_distributed_undo_idl_stamp: nautilus-distributed-undo.idl $(ORBIT_IDL)
$(ORBIT_IDL) $(LIBNAUTILUS_IDL_INCLUDES) $<
touch $@
diff --git a/libnautilus/nautilus-view-standard-main.c b/libnautilus/nautilus-view-standard-main.c
index 371e2d432..a0f35746f 100644
--- a/libnautilus/nautilus-view-standard-main.c
+++ b/libnautilus/nautilus-view-standard-main.c
@@ -229,7 +229,6 @@ nautilus_view_standard_main_multi (const char *executable_name,
}
gnome_vfs_shutdown ();
- bonobo_ui_debug_shutdown ();
return EXIT_SUCCESS;
}
diff --git a/nautilus-launch-icon.png b/nautilus-launch-icon.png
deleted file mode 100644
index 87cfae569..000000000
--- a/nautilus-launch-icon.png
+++ /dev/null
Binary files differ
diff --git a/src/file-manager/fm-properties-window.c b/src/file-manager/fm-properties-window.c
index 2f67b341a..f79729c66 100644
--- a/src/file-manager/fm-properties-window.c
+++ b/src/file-manager/fm-properties-window.c
@@ -32,12 +32,10 @@
#include <eel/eel-gnome-extensions.h>
#include <eel/eel-gtk-extensions.h>
#include <eel/eel-gtk-macros.h>
-#include <eel/eel-image.h>
#include <eel/eel-labeled-image.h>
#include <eel/eel-stock-dialogs.h>
#include <eel/eel-string.h>
#include <eel/eel-vfs-extensions.h>
-#include <eel/eel-viewport.h>
#include <eel/eel-wrap-table.h>
#include <gtk/gtkalignment.h>
#include <gtk/gtkcheckbutton.h>
@@ -46,6 +44,7 @@
#include <gtk/gtkfilesel.h>
#include <gtk/gtkhbox.h>
#include <gtk/gtkhseparator.h>
+#include <gtk/gtkimage.h>
#include <gtk/gtklabel.h>
#include <gtk/gtkmain.h>
#include <gtk/gtknotebook.h>
@@ -250,20 +249,18 @@ get_pixbuf_for_properties_window (NautilusFile *file)
}
static void
-update_properties_window_icon (EelImage *image)
+update_properties_window_icon (GtkImage *image)
{
GdkPixbuf *pixbuf;
NautilusFile *file;
- g_assert (EEL_IS_IMAGE (image));
-
file = g_object_get_data (G_OBJECT (image), "nautilus_file");
g_assert (NAUTILUS_IS_FILE (file));
pixbuf = get_pixbuf_for_properties_window (file);
- eel_image_set_pixbuf (image, pixbuf);
+ gtk_image_set_from_pixbuf (image, pixbuf);
g_object_unref (pixbuf);
}
@@ -299,13 +296,13 @@ fm_properties_window_drag_data_received (GtkWidget *widget, GdkDragContext *cont
{
char **uris;
gboolean exactly_one;
- EelImage *image;
+ GtkImage *image;
GtkWindow *window;
uris = g_strsplit (selection_data->data, "\r\n", 0);
exactly_one = uris[0] != NULL && uris[1] == NULL;
- image = EEL_IMAGE (widget);
+ image = GTK_IMAGE (widget);
window = GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (image)));
@@ -347,7 +344,7 @@ create_image_widget_for_file (NautilusFile *file)
pixbuf = get_pixbuf_for_properties_window (file);
- image = eel_image_new (NULL);
+ image = gtk_image_new ();
/* prepare the image to receive dropped objects to assign custom images */
gtk_drag_dest_set (GTK_WIDGET (image),
@@ -359,7 +356,7 @@ create_image_widget_for_file (NautilusFile *file)
G_CALLBACK (fm_properties_window_drag_data_received), NULL);
- eel_image_set_pixbuf (EEL_IMAGE (image), pixbuf);
+ gtk_image_set_from_pixbuf (GTK_IMAGE (image), pixbuf);
g_object_unref (pixbuf);
diff --git a/src/file-manager/nautilus-indexing-info.c b/src/file-manager/nautilus-indexing-info.c
index 3d9400bf6..23c68c0e0 100644
--- a/src/file-manager/nautilus-indexing-info.c
+++ b/src/file-manager/nautilus-indexing-info.c
@@ -271,7 +271,7 @@ show_indexing_info_dialog (void)
}
if (dialogs == NULL) {
dialogs = g_new0 (IndexingInfoDialogs, 1);
- g_atexit (destroy_indexing_info_dialogs_on_exit);
+ eel_debug_call_at_shutdown (destroy_indexing_info_dialogs_on_exit, NULL);
dialogs->last_index_time_dialog = last_index_time_dialog_new ();
dialogs->index_in_progress_dialog = index_progress_dialog_new ();
diff --git a/src/nautilus-component-adapter-factory.c b/src/nautilus-component-adapter-factory.c
index 1b5303998..c1be4166b 100644
--- a/src/nautilus-component-adapter-factory.c
+++ b/src/nautilus-component-adapter-factory.c
@@ -22,17 +22,18 @@
/* nautilus-component-adapter-factory.c - client wrapper for the
* special adapter component, which wraps Bonobo components as
- * Nautilus Views and in the process keeps evil syncrhonous I/O out of
+ * Nautilus Views and in the process keeps evil synchronous I/O out of
* the Nautilus process itself.
*/
#include <config.h>
#include "nautilus-component-adapter-factory.h"
-#include <bonobo/bonobo-moniker-util.h>
#include <bonobo/bonobo-exception.h>
+#include <bonobo/bonobo-moniker-util.h>
#include <bonobo/bonobo-object.h>
-#include <eel/eel-gtk-macros.h>
+#include <eel/eel-debug.h>
+#include <libgnome/gnome-macros.h>
#include <libnautilus-adapter/nautilus-adapter-factory.h>
#define NAUTILUS_COMPONENT_ADAPTER_FACTORY_IID "OAFIID:nautilus_adapter_factory:fd24ecfc-0a6e-47ab-bc53-69d7487c6ad4"
@@ -43,18 +44,15 @@ struct NautilusComponentAdapterFactoryDetails {
static NautilusComponentAdapterFactory *global_component_adapter_factory = NULL;
-static void nautilus_component_adapter_factory_class_init (NautilusComponentAdapterFactoryClass *klass);
-static void nautilus_component_adapter_factory_init (NautilusComponentAdapterFactory *factory);
-
-EEL_CLASS_BOILERPLATE (NautilusComponentAdapterFactory,
- nautilus_component_adapter_factory,
- GTK_TYPE_OBJECT)
-
+GNOME_CLASS_BOILERPLATE (NautilusComponentAdapterFactory, nautilus_component_adapter_factory,
+ GtkObject, GTK_TYPE_OBJECT)
static void
activate_factory (NautilusComponentAdapterFactory *factory)
{
- factory->details->corba_factory = bonobo_get_object (NAUTILUS_COMPONENT_ADAPTER_FACTORY_IID, "IDL:Nautilus/ComponentAdapterFactory:1.0", NULL);
+ factory->details->corba_factory = bonobo_get_object
+ (NAUTILUS_COMPONENT_ADAPTER_FACTORY_IID,
+ "IDL:Nautilus/ComponentAdapterFactory:1.0", NULL);
}
static void
@@ -100,14 +98,16 @@ get_corba_factory (NautilusComponentAdapterFactory *factory)
CORBA_exception_free (&ev);
result = bonobo_object_dup_ref (factory->details->corba_factory, NULL);
+
if (need_unref) {
unref_factory (factory);
}
+
return result;
}
static void
-nautilus_component_adapter_factory_init (NautilusComponentAdapterFactory *factory)
+nautilus_component_adapter_factory_instance_init (NautilusComponentAdapterFactory *factory)
{
factory->details = g_new0 (NautilusComponentAdapterFactoryDetails, 1);
}
@@ -122,7 +122,7 @@ nautilus_component_adapter_factory_destroy (GtkObject *object)
release_factory (factory);
g_free (factory->details);
- EEL_CALL_PARENT (GTK_OBJECT_CLASS, destroy, (object));
+ GTK_OBJECT_CLASS (parent_class)->destroy (object);
}
static void
@@ -155,7 +155,7 @@ nautilus_component_adapter_factory_get (void)
gtk_object_sink (GTK_OBJECT (factory));
global_component_adapter_factory = factory;
- g_atexit (component_adapter_factory_at_exit_destructor);
+ eel_debug_call_at_shutdown (component_adapter_factory_at_exit_destructor);
}
return global_component_adapter_factory;
@@ -174,14 +174,20 @@ nautilus_component_adapter_factory_create_adapter (NautilusComponentAdapterFacto
nautilus_view = Bonobo_Unknown_queryInterface
(component, "IDL:Nautilus/View:1.0", &ev);
+ if (BONOBO_EX (&ev)) {
+ nautilus_view = CORBA_OBJECT_NIL;
+ }
- if (!CORBA_Object_is_nil (nautilus_view, &ev)) {
+ if (nautilus_view != CORBA_OBJECT_NIL) {
/* Object has the View interface, great! We might not
* need to adapt it.
*/
bonobo_control = Bonobo_Unknown_queryInterface
(component, "IDL:Bonobo/Control:1.0", &ev);
- if (!CORBA_Object_is_nil (bonobo_control, &ev)) {
+ if (BONOBO_EX (&ev)) {
+ bonobo_control = CORBA_OBJECT_NIL;
+ }
+ if (bonobo_control != CORBA_OBJECT_NIL) {
/* It has the control interface too, so all is peachy. */
bonobo_object_release_unref (bonobo_control, NULL);
} else {
@@ -193,9 +199,7 @@ nautilus_component_adapter_factory_create_adapter (NautilusComponentAdapterFacto
nautilus_view = CORBA_OBJECT_NIL;
}
} else {
- nautilus_view = CORBA_OBJECT_NIL;
/* No View interface, we must adapt the object */
-
corba_factory = get_corba_factory (factory);
nautilus_view = Nautilus_ComponentAdapterFactory_create_adapter
(corba_factory, component, &ev);
diff --git a/src/nautilus-main.c b/src/nautilus-main.c
index 939106770..59078642e 100644
--- a/src/nautilus-main.c
+++ b/src/nautilus-main.c
@@ -276,7 +276,9 @@ main (int argc, char *argv[])
}
poptFreeContext (popt_context);
+
gnome_vfs_shutdown ();
+ eel_debug_shut_down ();
bonobo_ui_debug_shutdown ();
/* If told to restart, exec() myself again. This is used when
diff --git a/src/nautilus-navigation-window-menus.c b/src/nautilus-navigation-window-menus.c
index 42c1a9d20..cadcd1ec5 100644
--- a/src/nautilus-navigation-window-menus.c
+++ b/src/nautilus-navigation-window-menus.c
@@ -44,6 +44,7 @@
#include <eel/eel-debug.h>
#include <eel/eel-glib-extensions.h>
#include <eel/eel-gnome-extensions.h>
+#include <eel/eel-gobject-extensions.h>
#include <eel/eel-gtk-extensions.h>
#include <eel/eel-stock-dialogs.h>
#include <eel/eel-string.h>
@@ -971,7 +972,7 @@ get_bookmark_list (void)
{
if (bookmarks == NULL) {
bookmarks = nautilus_bookmark_list_new ();
- g_atexit (free_bookmark_list);
+ eel_debug_call_at_shutdown (free_bookmark_list);
}
return bookmarks;
@@ -1092,15 +1093,14 @@ nautilus_window_initialize_go_menu (NautilusWindow *window)
/* Recreate bookmarks part of menu if history list changes
* or if icon theme changes.
*/
- gtk_signal_connect_object_while_alive (nautilus_signaller_get_current (),
+ eel_signal_connect_object_while_alive (nautilus_signaller_get_current (),
"history_list_changed",
G_CALLBACK (schedule_refresh_go_menu),
- GTK_OBJECT (window));
-
- gtk_signal_connect_object_while_alive (nautilus_icon_factory_get (),
+ G_OBJECT (window));
+ eel_signal_connect_object_while_alive (G_OBJECT (nautilus_icon_factory_get ()),
"icons_changed",
G_CALLBACK (schedule_refresh_go_menu),
- GTK_OBJECT (window));
+ G_OBJECT (window));
}
/**
diff --git a/src/nautilus-navigation-window.c b/src/nautilus-navigation-window.c
index afe9dd2e4..44c8542a7 100644
--- a/src/nautilus-navigation-window.c
+++ b/src/nautilus-navigation-window.c
@@ -42,6 +42,7 @@
#include <bonobo/bonobo-exception.h>
#include <bonobo/bonobo-property-bag-client.h>
#include <bonobo/bonobo-ui-util.h>
+#include <eel/eel-debug.h>
#include <eel/eel-gdk-extensions.h>
#include <eel/eel-gdk-pixbuf-extensions.h>
#include <eel/eel-generous-bin.h>
@@ -188,7 +189,7 @@ nautilus_window_class_init (NautilusWindowClass *klass)
(pixbuf, &mini_icon_pixmap, &mini_icon_mask,
EEL_STANDARD_ALPHA_THRESHHOLD);
g_object_unref (pixbuf);
- g_atexit (unref_mini_icon);
+ eel_debug_call_at_shutdown (unref_mini_icon);
}
g_free (filename);
}
@@ -1785,7 +1786,7 @@ add_to_history_list (NautilusBookmark *bookmark)
g_return_if_fail (NAUTILUS_IS_BOOKMARK (bookmark));
if (!free_history_list_is_set_up) {
- g_atexit (free_history_list);
+ eel_debug_call_at_shutdown (free_history_list);
free_history_list_is_set_up = TRUE;
}
diff --git a/src/nautilus-object-window.c b/src/nautilus-object-window.c
index afe9dd2e4..44c8542a7 100644
--- a/src/nautilus-object-window.c
+++ b/src/nautilus-object-window.c
@@ -42,6 +42,7 @@
#include <bonobo/bonobo-exception.h>
#include <bonobo/bonobo-property-bag-client.h>
#include <bonobo/bonobo-ui-util.h>
+#include <eel/eel-debug.h>
#include <eel/eel-gdk-extensions.h>
#include <eel/eel-gdk-pixbuf-extensions.h>
#include <eel/eel-generous-bin.h>
@@ -188,7 +189,7 @@ nautilus_window_class_init (NautilusWindowClass *klass)
(pixbuf, &mini_icon_pixmap, &mini_icon_mask,
EEL_STANDARD_ALPHA_THRESHHOLD);
g_object_unref (pixbuf);
- g_atexit (unref_mini_icon);
+ eel_debug_call_at_shutdown (unref_mini_icon);
}
g_free (filename);
}
@@ -1785,7 +1786,7 @@ add_to_history_list (NautilusBookmark *bookmark)
g_return_if_fail (NAUTILUS_IS_BOOKMARK (bookmark));
if (!free_history_list_is_set_up) {
- g_atexit (free_history_list);
+ eel_debug_call_at_shutdown (free_history_list);
free_history_list_is_set_up = TRUE;
}
diff --git a/src/nautilus-preferences-dialog.c b/src/nautilus-preferences-dialog.c
index 620fcd5c6..c1f07f1d6 100644
--- a/src/nautilus-preferences-dialog.c
+++ b/src/nautilus-preferences-dialog.c
@@ -28,6 +28,7 @@
#include "libnautilus-private/nautilus-global-preferences.h"
#include "libnautilus-private/nautilus-sidebar-functions.h"
#include "nautilus-theme-selector.h"
+#include <eel/eel-debug.h>
#include <eel/eel-gtk-extensions.h>
#include <eel/eel-preferences-box.h>
#include <gtk/gtkdialog.h>
@@ -576,7 +577,7 @@ global_preferences_get_dialog (void)
if (preferences_dialog == NULL) {
preferences_dialog = preferences_dialog_create ();
- g_atexit (preferences_dialog_destroy);
+ eel_debug_call_at_shutdown (preferences_dialog_destroy);
}
g_assert (GTK_IS_DIALOG (preferences_dialog));
diff --git a/src/nautilus-property-browser.c b/src/nautilus-property-browser.c
index cd17bad0a..75b63de7a 100644
--- a/src/nautilus-property-browser.c
+++ b/src/nautilus-property-browser.c
@@ -40,12 +40,10 @@
#include <eel/eel-gtk-extensions.h>
#include <eel/eel-gtk-macros.h>
#include <eel/eel-image-table.h>
-#include <eel/eel-image.h>
#include <eel/eel-labeled-image.h>
#include <eel/eel-stock-dialogs.h>
#include <eel/eel-string.h>
#include <eel/eel-vfs-extensions.h>
-#include <eel/eel-viewport.h>
#include <eel/eel-xml-extensions.h>
#include <libxml/parser.h>
#include <libxml/xmlmemory.h>
@@ -277,8 +275,7 @@ nautilus_property_browser_init (GtkObject *object)
gtk_container_set_border_width (GTK_CONTAINER (property_browser->details->category_container), 0);
property_browser->details->category_position = -1;
- viewport = eel_viewport_new (NULL, NULL);
- eel_viewport_set_never_smooth (EEL_VIEWPORT (viewport), FALSE);
+ viewport = gtk_viewport_new (NULL, NULL);
gtk_widget_show (viewport);
gtk_viewport_set_shadow_type(GTK_VIEWPORT(viewport), GTK_SHADOW_NONE);
@@ -1478,7 +1475,7 @@ element_clicked_callback (GtkWidget *image_table,
GdkPixbuf *pixbuf;
int x_delta, y_delta;
const char *element_name;
- EelArtIPoint scroll_offset;
+ int scroll_offset_x, scroll_offset_y;
g_return_if_fail (EEL_IS_IMAGE_TABLE (image_table));
g_return_if_fail (EEL_IS_LABELED_IMAGE (child));
@@ -1516,10 +1513,8 @@ element_clicked_callback (GtkWidget *image_table,
NULL);
/* compute the offsets for dragging */
- scroll_offset = eel_viewport_get_scroll_offset (EEL_VIEWPORT (image_table->parent));
-
if (strcmp (drag_types[0].target, "application/x-color")) {
- /*it's not a color, so, for now, it must be an image */
+ /* it's not a color, so, for now, it must be an image */
/* fiddle with the category to handle the "reset" case properly */
char * save_category = property_browser->details->category;
if (eel_strcmp (property_browser->details->category, "colors") == 0) {
@@ -1531,8 +1526,11 @@ element_clicked_callback (GtkWidget *image_table,
y_delta = gdk_pixbuf_get_height (pixbuf) / 2;
} else {
pixbuf = make_color_drag_image (property_browser, element_name, TRUE);
- x_delta = event->x - child->allocation.x - scroll_offset.x;
- y_delta = event->y - child->allocation.y - scroll_offset.y;
+ gdk_window_get_position (GTK_VIEWPORT (image_table->parent)->bin_window,
+ &scroll_offset_x,
+ &scroll_offset_y);
+ x_delta = event->x - child->allocation.x - scroll_offset_x;
+ y_delta = event->y - child->allocation.y - scroll_offset_y;
}
/* set the pixmap and mask for dragging */
@@ -1940,8 +1938,7 @@ nautilus_property_browser_update_contents (NautilusPropertyBrowser *property_bro
/* allocate a new container, with a scrollwindow and viewport */
property_browser->details->content_frame = gtk_scrolled_window_new (NULL, NULL);
gtk_container_set_border_width (GTK_CONTAINER (property_browser->details->content_frame), 0);
- viewport = eel_viewport_new (NULL, NULL);
- eel_viewport_set_never_smooth (EEL_VIEWPORT (viewport), FALSE);
+ viewport = gtk_viewport_new (NULL, NULL);
gtk_widget_show(viewport);
gtk_viewport_set_shadow_type(GTK_VIEWPORT(viewport), GTK_SHADOW_IN);
background = eel_get_widget_background (viewport);
diff --git a/src/nautilus-search-bar-criterion.c b/src/nautilus-search-bar-criterion.c
index 238924927..78a40fa07 100644
--- a/src/nautilus-search-bar-criterion.c
+++ b/src/nautilus-search-bar-criterion.c
@@ -195,7 +195,7 @@ static char * get_owner_location_for
static void make_emblem_value_menu (NautilusSearchBarCriterion *criterion);
static void criterion_type_changed_callback (GtkObject *object,
gpointer data);
-static void emblems_changed_callback (GtkObject *signaller,
+static void emblems_changed_callback (GObject *signaller,
gpointer data);
static gboolean criterion_type_already_is_displayed (GSList *criteria,
NautilusSearchBarCriterionType criterion_number);
@@ -233,8 +233,8 @@ nautilus_search_bar_criterion_destroy (GtkObject *object)
criterion = NAUTILUS_SEARCH_BAR_CRITERION (object);
/* FIXME bugzilla.gnome.org 42437: need more freeage */
- gtk_signal_disconnect_by_data (nautilus_signaller_get_current (),
- criterion);
+ g_signal_handlers_disconnect_by_func (nautilus_signaller_get_current (),
+ G_CALLBACK (emblems_changed_callback), criterion);
/* nautilus_undo_editable_set_undo_key (GTK_EDITABLE (criterion->details->value_entry), FALSE);
nautilus_undo_tear_down_nautilus_entry_for_undo (criterion->details->value_entry);
*/
@@ -297,14 +297,10 @@ nautilus_search_bar_criterion_new_from_values (NautilusSearchBarCriterionType ty
details->bar = bar;
details->box = gtk_hwrap_box_new (FALSE);
- g_signal_connect (details->box,
- "need_reallocation",
- G_CALLBACK (queue_bar_resize_callback),
- bar);
- gtk_signal_connect (nautilus_signaller_get_current (),
- "emblems_changed",
- G_CALLBACK (emblems_changed_callback),
- criterion);
+ g_signal_connect (details->box, "need_reallocation",
+ G_CALLBACK (queue_bar_resize_callback), bar);
+ g_signal_connect (nautilus_signaller_get_current (), "emblems_changed",
+ G_CALLBACK (emblems_changed_callback), criterion);
search_criteria_option_menu = gtk_option_menu_new ();
@@ -317,10 +313,8 @@ nautilus_search_bar_criterion_new_from_values (NautilusSearchBarCriterionType ty
g_free (context_stripped_criteria_title);
g_object_set_data (G_OBJECT(item), "type", GINT_TO_POINTER(i));
- g_signal_connect (item,
- "activate",
- G_CALLBACK (criterion_type_changed_callback),
- criterion);
+ g_signal_connect (item, "activate",
+ G_CALLBACK (criterion_type_changed_callback), criterion);
gtk_menu_append (GTK_MENU (search_criteria_menu),
item);
gtk_widget_show (item);
@@ -718,10 +712,8 @@ nautilus_search_bar_criterion_update_valid_criteria_choices (NautilusSearchBarCr
g_object_set_data (G_OBJECT(item), "type", GINT_TO_POINTER(i));
- g_signal_connect (item,
- "activate",
- G_CALLBACK (criterion_type_changed_callback),
- criterion);
+ g_signal_connect (item, "activate",
+ G_CALLBACK (criterion_type_changed_callback), criterion);
gtk_menu_append (GTK_MENU (new_menu),
item);
gtk_widget_show (item);
@@ -1052,13 +1044,12 @@ criterion_type_changed_callback (GtkObject *object,
}
static void
-emblems_changed_callback (GtkObject *signaller,
+emblems_changed_callback (GObject *signaller,
gpointer data)
{
NautilusSearchBarCriterion *criterion;
GtkWidget *menu_widget;
- g_return_if_fail (NAUTILUS_IS_SEARCH_BAR_CRITERION (data));
criterion = NAUTILUS_SEARCH_BAR_CRITERION (data);
if (criterion->details->type == NAUTILUS_EMBLEM_SEARCH_CRITERION) {
@@ -1077,8 +1068,6 @@ criterion_is_of_type (gconstpointer a,
NautilusSearchBarCriterion *criterion;
NautilusSearchBarCriterionType type;
- g_return_val_if_fail (NAUTILUS_IS_SEARCH_BAR_CRITERION (a),
- NAUTILUS_NUMBER_OF_SEARCH_CRITERIA);
criterion = NAUTILUS_SEARCH_BAR_CRITERION (a);
type = (NautilusSearchBarCriterionType) b;
diff --git a/src/nautilus-sidebar-title.c b/src/nautilus-sidebar-title.c
index 47f8e5193..80da63796 100644
--- a/src/nautilus-sidebar-title.c
+++ b/src/nautilus-sidebar-title.c
@@ -38,9 +38,9 @@
#include <eel/eel-glib-extensions.h>
#include <eel/eel-gtk-extensions.h>
#include <eel/eel-gtk-macros.h>
-#include <eel/eel-image-with-background.h>
#include <eel/eel-string.h>
#include <gtk/gtkhbox.h>
+#include <gtk/gtkimage.h>
#include <gtk/gtklabel.h>
#include <gtk/gtksignal.h>
#include <gtk/gtkwidget.h>
@@ -184,7 +184,7 @@ nautilus_sidebar_title_init (NautilusSidebarTitle *sidebar_title)
G_CALLBACK (realize_callback), NULL);
/* Create the icon */
- sidebar_title->details->icon = eel_image_new_with_background (NULL);
+ sidebar_title->details->icon = gtk_image_new ();
gtk_box_pack_start (GTK_BOX (sidebar_title), sidebar_title->details->icon, 0, 0, 0);
gtk_widget_show (sidebar_title->details->icon);
@@ -493,7 +493,7 @@ update_icon (NautilusSidebarTitle *sidebar_title)
}
if (!leave_pixbuf_unchanged) {
- eel_image_set_pixbuf (EEL_IMAGE (sidebar_title->details->icon), pixbuf);
+ gtk_image_set_from_pixbuf (GTK_IMAGE (sidebar_title->details->icon), pixbuf);
}
}
@@ -683,8 +683,7 @@ add_emblem (NautilusSidebarTitle *sidebar_title, GdkPixbuf *pixbuf)
{
GtkWidget *image_widget;
- image_widget = eel_image_new_with_background (NULL);
- eel_image_set_pixbuf (EEL_IMAGE (image_widget), pixbuf);
+ image_widget = gtk_image_new_from_pixbuf (pixbuf);
gtk_widget_show (image_widget);
gtk_container_add (GTK_CONTAINER (sidebar_title->details->emblem_box), image_widget);
}
diff --git a/src/nautilus-signaller.c b/src/nautilus-signaller.c
index b4f9d4361..c4ee2c120 100644
--- a/src/nautilus-signaller.c
+++ b/src/nautilus-signaller.c
@@ -29,11 +29,11 @@
#include <config.h>
#include "nautilus-signaller.h"
-#include <gtk/gtksignal.h>
-#include <eel/eel-gtk-macros.h>
+#include <eel/eel-debug.h>
+#include <libgnome/gnome-macros.h>
-typedef GtkObject NautilusSignaller;
-typedef GtkObjectClass NautilusSignallerClass;
+typedef GObject NautilusSignaller;
+typedef GObjectClass NautilusSignallerClass;
enum {
HISTORY_LIST_CHANGED,
@@ -43,63 +43,46 @@ enum {
static guint signals[LAST_SIGNAL];
-static GtkObject *global_signaller = NULL;
+static GType nautilus_signaller_get_type (void);
-static GtkType nautilus_signaller_get_type (void);
-static void nautilus_signaller_class_init (gpointer klass);
-static void nautilus_signaller_init (gpointer object,
- gpointer klass);
+GNOME_CLASS_BOILERPLATE (NautilusSignaller, nautilus_signaller,
+ GObject, G_TYPE_OBJECT)
-EEL_CLASS_BOILERPLATE (NautilusSignaller,
- nautilus_signaller,
- GTK_TYPE_OBJECT)
+GObject *
+nautilus_signaller_get_current (void)
+{
+ static GObject *global_signaller = NULL;
+
+ if (global_signaller == NULL) {
+ global_signaller = g_object_new (nautilus_signaller_get_type (), NULL);
+ eel_debug_call_at_shutdown_with_data (g_object_unref, global_signaller);
+ }
+
+ return global_signaller;
+}
static void
-nautilus_signaller_class_init (gpointer klass)
+nautilus_signaller_instance_init (NautilusSignaller *signaller)
{
- GtkObjectClass *object_class;
+}
- object_class = GTK_OBJECT_CLASS (klass);
-
+static void
+nautilus_signaller_class_init (NautilusSignallerClass *class)
+{
signals[HISTORY_LIST_CHANGED] =
g_signal_new ("history_list_changed",
- G_TYPE_FROM_CLASS (object_class),
+ G_TYPE_FROM_CLASS (class),
G_SIGNAL_RUN_LAST,
0,
NULL, NULL,
- gtk_marshal_NONE__NONE,
+ g_cclosure_marshal_VOID__VOID,
G_TYPE_NONE, 0);
signals[EMBLEMS_CHANGED] =
g_signal_new ("emblems_changed",
- G_TYPE_FROM_CLASS (object_class),
+ G_TYPE_FROM_CLASS (class),
G_SIGNAL_RUN_LAST,
0,
NULL, NULL,
- gtk_marshal_NONE__NONE,
+ g_cclosure_marshal_VOID__VOID,
G_TYPE_NONE, 0);
}
-
-static void
-nautilus_signaller_init (gpointer object, gpointer klass)
-{
- /* placeholder to allow use of boilerplate macro */
-}
-
-static void
-unref_global_signaller (void)
-{
- g_object_unref (global_signaller);
-}
-
-GtkObject *
-nautilus_signaller_get_current (void)
-{
- if (global_signaller == NULL) {
- global_signaller = g_object_new (nautilus_signaller_get_type (), NULL);
- g_object_ref (global_signaller);
- gtk_object_sink (GTK_OBJECT (global_signaller));
- g_atexit (unref_global_signaller);
- }
-
- return global_signaller;
-}
diff --git a/src/nautilus-signaller.h b/src/nautilus-signaller.h
index 0998a6e35..eff25a905 100644
--- a/src/nautilus-signaller.h
+++ b/src/nautilus-signaller.h
@@ -29,7 +29,7 @@
#ifndef NAUTILUS_SIGNALLER_H
#define NAUTILUS_SIGNALLER_H
-#include <gtk/gtkobject.h>
+#include <glib-object.h>
/* NautilusSignaller is a class that manages signals between
disconnected Nautilus code. Nautilus objects connect to these signals
@@ -41,6 +41,6 @@
*/
/* Get the one and only NautilusSignaller to connect with or emit signals for */
-GtkObject *nautilus_signaller_get_current (void);
+GObject *nautilus_signaller_get_current (void);
#endif /* NAUTILUS_SIGNALLER_H */
diff --git a/src/nautilus-spatial-window.c b/src/nautilus-spatial-window.c
index afe9dd2e4..44c8542a7 100644
--- a/src/nautilus-spatial-window.c
+++ b/src/nautilus-spatial-window.c
@@ -42,6 +42,7 @@
#include <bonobo/bonobo-exception.h>
#include <bonobo/bonobo-property-bag-client.h>
#include <bonobo/bonobo-ui-util.h>
+#include <eel/eel-debug.h>
#include <eel/eel-gdk-extensions.h>
#include <eel/eel-gdk-pixbuf-extensions.h>
#include <eel/eel-generous-bin.h>
@@ -188,7 +189,7 @@ nautilus_window_class_init (NautilusWindowClass *klass)
(pixbuf, &mini_icon_pixmap, &mini_icon_mask,
EEL_STANDARD_ALPHA_THRESHHOLD);
g_object_unref (pixbuf);
- g_atexit (unref_mini_icon);
+ eel_debug_call_at_shutdown (unref_mini_icon);
}
g_free (filename);
}
@@ -1785,7 +1786,7 @@ add_to_history_list (NautilusBookmark *bookmark)
g_return_if_fail (NAUTILUS_IS_BOOKMARK (bookmark));
if (!free_history_list_is_set_up) {
- g_atexit (free_history_list);
+ eel_debug_call_at_shutdown (free_history_list);
free_history_list_is_set_up = TRUE;
}
diff --git a/src/nautilus-theme-selector.c b/src/nautilus-theme-selector.c
index a61bf6925..3bf3ce778 100644
--- a/src/nautilus-theme-selector.c
+++ b/src/nautilus-theme-selector.c
@@ -34,14 +34,13 @@
#include <eel/eel-image-chooser.h>
#include <eel/eel-stock-dialogs.h>
#include <eel/eel-string.h>
-#include <eel/eel-viewport.h>
#include <gtk/gtkalignment.h>
#include <gtk/gtkbutton.h>
#include <gtk/gtkfilesel.h>
#include <gtk/gtkhbox.h>
#include <gtk/gtkmain.h>
+#include <gtk/gtkscrolledwindow.h>
#include <gtk/gtksignal.h>
-#include <gtk/gtkwindow.h>
#include <libgnome/gnome-i18n.h>
#include <libgnome/gnome-util.h>
#include <libnautilus-private/nautilus-global-preferences.h>
diff --git a/src/nautilus-window-menus.c b/src/nautilus-window-menus.c
index 42c1a9d20..cadcd1ec5 100644
--- a/src/nautilus-window-menus.c
+++ b/src/nautilus-window-menus.c
@@ -44,6 +44,7 @@
#include <eel/eel-debug.h>
#include <eel/eel-glib-extensions.h>
#include <eel/eel-gnome-extensions.h>
+#include <eel/eel-gobject-extensions.h>
#include <eel/eel-gtk-extensions.h>
#include <eel/eel-stock-dialogs.h>
#include <eel/eel-string.h>
@@ -971,7 +972,7 @@ get_bookmark_list (void)
{
if (bookmarks == NULL) {
bookmarks = nautilus_bookmark_list_new ();
- g_atexit (free_bookmark_list);
+ eel_debug_call_at_shutdown (free_bookmark_list);
}
return bookmarks;
@@ -1092,15 +1093,14 @@ nautilus_window_initialize_go_menu (NautilusWindow *window)
/* Recreate bookmarks part of menu if history list changes
* or if icon theme changes.
*/
- gtk_signal_connect_object_while_alive (nautilus_signaller_get_current (),
+ eel_signal_connect_object_while_alive (nautilus_signaller_get_current (),
"history_list_changed",
G_CALLBACK (schedule_refresh_go_menu),
- GTK_OBJECT (window));
-
- gtk_signal_connect_object_while_alive (nautilus_icon_factory_get (),
+ G_OBJECT (window));
+ eel_signal_connect_object_while_alive (G_OBJECT (nautilus_icon_factory_get ()),
"icons_changed",
G_CALLBACK (schedule_refresh_go_menu),
- GTK_OBJECT (window));
+ G_OBJECT (window));
}
/**
diff --git a/src/nautilus-window.c b/src/nautilus-window.c
index afe9dd2e4..44c8542a7 100644
--- a/src/nautilus-window.c
+++ b/src/nautilus-window.c
@@ -42,6 +42,7 @@
#include <bonobo/bonobo-exception.h>
#include <bonobo/bonobo-property-bag-client.h>
#include <bonobo/bonobo-ui-util.h>
+#include <eel/eel-debug.h>
#include <eel/eel-gdk-extensions.h>
#include <eel/eel-gdk-pixbuf-extensions.h>
#include <eel/eel-generous-bin.h>
@@ -188,7 +189,7 @@ nautilus_window_class_init (NautilusWindowClass *klass)
(pixbuf, &mini_icon_pixmap, &mini_icon_mask,
EEL_STANDARD_ALPHA_THRESHHOLD);
g_object_unref (pixbuf);
- g_atexit (unref_mini_icon);
+ eel_debug_call_at_shutdown (unref_mini_icon);
}
g_free (filename);
}
@@ -1785,7 +1786,7 @@ add_to_history_list (NautilusBookmark *bookmark)
g_return_if_fail (NAUTILUS_IS_BOOKMARK (bookmark));
if (!free_history_list_is_set_up) {
- g_atexit (free_history_list);
+ eel_debug_call_at_shutdown (free_history_list);
free_history_list_is_set_up = TRUE;
}
diff --git a/test/test-nautilus-preferences-change.c b/test/test-nautilus-preferences-change.c
index 4d968bd95..122250f6a 100644
--- a/test/test-nautilus-preferences-change.c
+++ b/test/test-nautilus-preferences-change.c
@@ -1,7 +1,5 @@
#include "test.h"
-#include <eel/eel-image.h>
-#include <eel/eel-image-with-background.h>
#include <eel/eel-string-picker.h>
#include <libnautilus-private/nautilus-global-preferences.h>
#include <unistd.h>
diff --git a/test/test-nautilus-preferences-display.c b/test/test-nautilus-preferences-display.c
index ae4a0f311..5dae617d5 100644
--- a/test/test-nautilus-preferences-display.c
+++ b/test/test-nautilus-preferences-display.c
@@ -1,7 +1,5 @@
#include "test.h"
-#include <eel/eel-image.h>
-#include <eel/eel-image-with-background.h>
#include <eel/eel-text-caption.h>
#include <libnautilus-private/nautilus-global-preferences.h>
diff --git a/test/test-nautilus-wrap-table.c b/test/test-nautilus-wrap-table.c
index 9298a1956..a62e398f5 100644
--- a/test/test-nautilus-wrap-table.c
+++ b/test/test-nautilus-wrap-table.c
@@ -1,7 +1,6 @@
#include "test.h"
#include <eel/eel-wrap-table.h>
-#include <eel/eel-viewport.h>
#include <eel/eel-labeled-image.h>
#include <libnautilus-private/nautilus-customization-data.h>
#include <libnautilus-private/nautilus-icon-factory.h>
diff --git a/test/test.c b/test/test.c
index f7efdf7ec..5550d035c 100644
--- a/test/test.c
+++ b/test/test.c
@@ -127,33 +127,6 @@ test_pixbuf_new_named (const char *name, float scale)
}
GtkWidget *
-test_image_new (const char *pixbuf_name,
- float scale,
- gboolean with_background)
-{
- GtkWidget *image;
-
- if (with_background) {
- image = eel_image_new_with_background (NULL);
- } else {
- image = eel_image_new (NULL);
- }
-
- if (pixbuf_name != NULL) {
- GdkPixbuf *pixbuf;
-
- pixbuf = test_pixbuf_new_named (pixbuf_name, scale);
-
- if (pixbuf != NULL) {
- eel_image_set_pixbuf (EEL_IMAGE (image), pixbuf);
- g_object_unref (pixbuf);
- }
- }
-
- return image;
-}
-
-GtkWidget *
test_label_new (const char *text,
gboolean with_background,
int num_sizes_larger)
diff --git a/test/test.h b/test/test.h
index c3ccb4321..12f88254f 100644
--- a/test/test.h
+++ b/test/test.h
@@ -16,8 +16,6 @@
#include <eel/eel-glib-extensions.h>
#include <eel/eel-gnome-extensions.h>
#include <eel/eel-gtk-extensions.h>
-#include <eel/eel-image-with-background.h>
-#include <eel/eel-image.h>
#include <eel/eel-string-list.h>
#include <eel/eel-string.h>
#include <libnautilus-private/nautilus-file-utilities.h>
@@ -39,9 +37,6 @@ void test_gtk_widget_set_background_color (GtkWidget *wi
const char *color_spec);
GdkPixbuf *test_pixbuf_new_named (const char *name,
float scale);
-GtkWidget *test_image_new (const char *pixbuf_name,
- float scale,
- gboolean with_background);
GtkWidget *test_label_new (const char *text,
gboolean with_background,
int num_sizes_larger);