Commit bdcd4787 authored by Darin Adler's avatar Darin Adler

Tons of files. More GtkObject -> GObject stuff.

	* Tons of files.
	More GtkObject -> GObject stuff.
parent 137cfdb8
......@@ -223,7 +223,7 @@ notes_load_metainfo (Notes *notes)
g_list_free (attributes);
gtk_signal_connect (GTK_OBJECT (notes->file),
g_signal_connect (G_OBJECT (notes->file),
"changed",
GTK_SIGNAL_FUNC (load_note_text_from_metadata),
notes);
......@@ -376,10 +376,10 @@ make_notes_view (const char *iid, gpointer callback_data)
background = eel_get_widget_background (notes->note_text_field);
eel_background_set_color (background, NOTES_DEFAULT_BACKGROUND_COLOR);
gtk_signal_connect (GTK_OBJECT (notes->note_text_field), "focus_out_event",
g_signal_connect (G_OBJECT (notes->note_text_field), "focus_out_event",
GTK_SIGNAL_FUNC (on_text_field_focus_out_event),
notes);
gtk_signal_connect (GTK_OBJECT (notes->note_text_field), "changed",
g_signal_connect (G_OBJECT (notes->note_text_field), "changed",
GTK_SIGNAL_FUNC (on_changed),
notes);
......@@ -387,7 +387,7 @@ make_notes_view (const char *iid, gpointer callback_data)
/* Create CORBA object. */
notes->view = nautilus_view_new (vbox);
gtk_signal_connect (GTK_OBJECT (notes->view), "destroy", do_destroy, notes);
g_signal_connect (G_OBJECT (notes->view), "destroy", do_destroy, notes);
/* allocate a property bag to reflect the TAB_IMAGE property */
notes->property_bag = bonobo_property_bag_new (get_bonobo_properties, set_bonobo_properties, notes);
......@@ -397,7 +397,7 @@ make_notes_view (const char *iid, gpointer callback_data)
"image indicating that a note is present", 0);
/* handle events */
gtk_signal_connect (GTK_OBJECT (notes->view), "load_location",
g_signal_connect (G_OBJECT (notes->view), "load_location",
notes_load_location, notes);
/* handle selections */
......
......@@ -24,7 +24,7 @@ nautilus_sample_content_view_LDADD = \
$(top_builddir)/libnautilus/libnautilus.la \
$(MODULE_LIBS)
uidir = $(datadir)/gnome/ui
uidir = $(datadir)/gnome-2.0/ui
ui_DATA = nautilus-sample-content-view-ui.xml
serverdir = $(datadir)/server
......
......@@ -139,7 +139,7 @@ nautilus_sample_content_view_init (NautilusSampleContentView *view)
nautilus_view_construct (NAUTILUS_VIEW (view),
view->details->label);
gtk_signal_connect (GTK_OBJECT (view),
g_signal_connect (G_OBJECT (view),
"load_location",
sample_load_location_callback,
NULL);
......@@ -147,7 +147,7 @@ nautilus_sample_content_view_init (NautilusSampleContentView *view)
/* Get notified when our bonobo control is activated so we can
* merge menu & toolbar items into the shell's UI.
*/
gtk_signal_connect (GTK_OBJECT (nautilus_view_get_bonobo_control (NAUTILUS_VIEW (view))),
g_signal_connect (G_OBJECT (nautilus_view_get_bonobo_control (NAUTILUS_VIEW (view))),
"activate",
sample_merge_bonobo_items_callback,
view);
......
......@@ -24,7 +24,7 @@ nautilus_text_view_LDADD = \
$(NAUTILUS_PRIVATE_LIBS) \
$(NULL)
uidir = $(datadir)/gnome/ui
uidir = $(datadir)/gnome-2.0/ui
ui_DATA = nautilus-text-view-ui.xml
serverdir = $(datadir)/server
......
......@@ -159,13 +159,13 @@ nautilus_text_view_init (NautilusTextView *text_view)
text_view->details->zoomable = bonobo_zoomable_new ();
text_view->details->zoom_index = 3;
gtk_signal_connect (GTK_OBJECT (text_view->details->zoomable), "set_zoom_level",
g_signal_connect (G_OBJECT (text_view->details->zoomable), "set_zoom_level",
GTK_SIGNAL_FUNC (zoomable_set_zoom_level_callback), text_view);
gtk_signal_connect (GTK_OBJECT (text_view->details->zoomable), "zoom_in",
g_signal_connect (G_OBJECT (text_view->details->zoomable), "zoom_in",
GTK_SIGNAL_FUNC (zoomable_zoom_in_callback), text_view);
gtk_signal_connect (GTK_OBJECT (text_view->details->zoomable), "zoom_out",
g_signal_connect (G_OBJECT (text_view->details->zoomable), "zoom_out",
GTK_SIGNAL_FUNC (zoomable_zoom_out_callback), text_view);
gtk_signal_connect (GTK_OBJECT (text_view->details->zoomable), "zoom_to_fit",
g_signal_connect (G_OBJECT (text_view->details->zoomable), "zoom_to_fit",
GTK_SIGNAL_FUNC (zoomable_zoom_to_fit_callback), text_view);
bonobo_zoomable_set_parameters_full (text_view->details->zoomable,
......@@ -177,7 +177,7 @@ nautilus_text_view_init (NautilusTextView *text_view)
BONOBO_OBJECT (text_view->details->zoomable));
gtk_signal_connect (GTK_OBJECT (text_view),
g_signal_connect (G_OBJECT (text_view),
"load_location",
text_view_load_location_callback,
text_view);
......@@ -223,7 +223,7 @@ nautilus_text_view_init (NautilusTextView *text_view)
gtk_container_add (GTK_CONTAINER (text_view->details->container), scrolled_window);
/* get notified when we are activated so we can merge in our menu items */
gtk_signal_connect (GTK_OBJECT (nautilus_view_get_bonobo_control
g_signal_connect (G_OBJECT (nautilus_view_get_bonobo_control
(NAUTILUS_VIEW (text_view))),
"activate",
merge_bonobo_menu_items,
......@@ -779,7 +779,7 @@ merge_bonobo_menu_items (BonoboControl *control, gboolean state, gpointer user_d
nautilus_text_view_build_service_menu (text_view, control);
gtk_signal_connect (GTK_OBJECT (bonobo_control_get_ui_component (control)),
g_signal_connect (G_OBJECT (bonobo_control_get_ui_component (control)),
"ui_event", handle_ui_event, text_view);
nautilus_clipboard_set_up_editable_in_control (GTK_EDITABLE (text_view->details->text_display),
......
......@@ -52,13 +52,13 @@ throbber_make_object (BonoboGenericFactory *factory,
return NULL;
}
throbber = NAUTILUS_THROBBER (gtk_object_new (NAUTILUS_TYPE_THROBBER, NULL));
throbber = NAUTILUS_THROBBER (g_object_new (NAUTILUS_TYPE_THROBBER, NULL));
object_count++;
bonobo_control = nautilus_throbber_get_control (throbber);
gtk_signal_connect (GTK_OBJECT (bonobo_control), "destroy", throbber_object_destroyed, NULL);
g_signal_connect (G_OBJECT (bonobo_control), "destroy", throbber_object_destroyed, NULL);
return bonobo_control;
}
......
......@@ -52,10 +52,10 @@ tree_shlib_make_object (PortableServer_POA poa,
return CORBA_OBJECT_NIL;
}
view = NAUTILUS_TREE_VIEW (gtk_object_new (NAUTILUS_TYPE_TREE_VIEW, NULL));
view = NAUTILUS_TREE_VIEW (g_object_new (NAUTILUS_TYPE_TREE_VIEW, NULL));
#if 0
gtk_signal_connect (GTK_OBJECT (view), "destroy", tree_shlib_object_destroyed, NULL);
g_signal_connect (G_OBJECT (view), "destroy", tree_shlib_object_destroyed, NULL);
#endif
bonobo_activation_plugin_use (poa, impl_ptr);
......
......@@ -92,7 +92,7 @@ nautilus_tree_change_queue_new (void)
{
NautilusTreeChangeQueue *change_queue;
change_queue = NAUTILUS_TREE_CHANGE_QUEUE (gtk_object_new (NAUTILUS_TYPE_TREE_CHANGE_QUEUE, NULL));
change_queue = NAUTILUS_TREE_CHANGE_QUEUE (g_object_new (NAUTILUS_TYPE_TREE_CHANGE_QUEUE, NULL));
gtk_object_ref (GTK_OBJECT (change_queue));
gtk_object_sink (GTK_OBJECT (change_queue));
return change_queue;
......
......@@ -173,7 +173,7 @@ nautilus_tree_expansion_state_new (void)
{
NautilusTreeExpansionState *state;
state = NAUTILUS_TREE_EXPANSION_STATE (gtk_object_new (NAUTILUS_TYPE_TREE_EXPANSION_STATE, NULL));
state = NAUTILUS_TREE_EXPANSION_STATE (g_object_new (NAUTILUS_TYPE_TREE_EXPANSION_STATE, NULL));
gtk_object_ref (GTK_OBJECT (state));
gtk_object_sink (GTK_OBJECT (state));
return state;
......
......@@ -112,7 +112,7 @@ nautilus_tree_model_class_init (gpointer klass)
G_SIGNAL_RUN_LAST,
G_STRUCT_OFFSET (NautilusTreeModelClass, node_changed),
NULL, NULL,
gtk_marshal_NONE__POINTER,
gtk_marshal_VOID__POINTER,
G_TYPE_NONE, 1, GTK_TYPE_POINTER);
signals[NODE_REMOVED] =
......@@ -121,7 +121,7 @@ nautilus_tree_model_class_init (gpointer klass)
G_SIGNAL_RUN_LAST,
G_STRUCT_OFFSET (NautilusTreeModelClass, node_removed),
NULL, NULL,
gtk_marshal_NONE__POINTER,
gtk_marshal_VOID__POINTER,
G_TYPE_NONE, 1, GTK_TYPE_POINTER);
signals[NODE_BEING_RENAMED] =
......@@ -130,7 +130,7 @@ nautilus_tree_model_class_init (gpointer klass)
G_SIGNAL_RUN_LAST,
G_STRUCT_OFFSET (NautilusTreeModelClass, node_removed),
NULL, NULL,
gtk_marshal_NONE__POINTER_POINTER,
gtk_marshal_VOID__POINTER_POINTER,
G_TYPE_NONE, 2, G_TYPE_STRING, G_TYPE_STRING);
signals[DONE_LOADING_CHILDREN] =
......@@ -139,7 +139,7 @@ nautilus_tree_model_class_init (gpointer klass)
G_SIGNAL_RUN_LAST,
G_STRUCT_OFFSET (NautilusTreeModelClass, done_loading_children),
NULL, NULL,
gtk_marshal_NONE__POINTER,
gtk_marshal_VOID__POINTER,
G_TYPE_NONE, 1, GTK_TYPE_POINTER);
}
......@@ -202,7 +202,7 @@ nautilus_tree_model_new (const char *root_uri)
{
NautilusTreeModel *model;
model = NAUTILUS_TREE_MODEL (gtk_object_new (NAUTILUS_TYPE_TREE_MODEL, NULL));
model = NAUTILUS_TREE_MODEL (g_object_new (NAUTILUS_TYPE_TREE_MODEL, NULL));
gtk_object_ref (GTK_OBJECT (model));
gtk_object_sink (GTK_OBJECT (model));
......@@ -773,8 +773,8 @@ report_node_changed (NautilusTreeModel *model,
nautilus_tree_node_get_file (node),
node);
gtk_signal_emit (GTK_OBJECT (model),
signals[NODE_CHANGED],
g_signal_emit (G_OBJECT (model),
signals[NODE_CHANGED], 0,
node);
connect_unparented_nodes (model, node);
......@@ -786,8 +786,8 @@ report_node_changed (NautilusTreeModel *model,
if (strcmp (file_uri, node_uri) == 0) {
/* A normal change */
gtk_signal_emit (GTK_OBJECT (model),
signals[NODE_CHANGED],
g_signal_emit (G_OBJECT (model),
signals[NODE_CHANGED], 0,
node);
} else {
/* A move or rename - model it as a remove followed by an add */
......@@ -799,8 +799,8 @@ report_node_changed (NautilusTreeModel *model,
* it to propagate the expansion state from the old name to the
* new name
*/
gtk_signal_emit (GTK_OBJECT (model),
signals[NODE_BEING_RENAMED],
g_signal_emit (G_OBJECT (model),
signals[NODE_BEING_RENAMED], 0,
node->details->uri, file_uri);
report_node_removed (model, node);
......@@ -861,8 +861,8 @@ report_node_removed_internal (NautilusTreeModel *model,
forget_unparented_node (model, node);
if (signal) {
gtk_signal_emit (GTK_OBJECT (model),
signals[NODE_REMOVED],
g_signal_emit (G_OBJECT (model),
signals[NODE_REMOVED], 0,
node);
}
......@@ -883,8 +883,8 @@ static void
report_done_loading (NautilusTreeModel *model,
NautilusTreeNode *node)
{
gtk_signal_emit (GTK_OBJECT (model),
signals[DONE_LOADING_CHILDREN],
g_signal_emit (G_OBJECT (model),
signals[DONE_LOADING_CHILDREN], 0,
node);
}
......
......@@ -88,7 +88,7 @@ nautilus_tree_node_new (NautilusFile *file)
{
NautilusTreeNode *node;
node = NAUTILUS_TREE_NODE (gtk_object_new (NAUTILUS_TYPE_TREE_NODE, NULL));
node = NAUTILUS_TREE_NODE (g_object_new (NAUTILUS_TYPE_TREE_NODE, NULL));
gtk_object_ref (GTK_OBJECT (node));
gtk_object_sink (GTK_OBJECT (node));
......
......@@ -210,55 +210,55 @@ nautilus_tree_view_init_dnd (NautilusTreeView *view)
| GDK_ACTION_ASK);
gtk_signal_connect (GTK_OBJECT (view->details->tree),
g_signal_connect (G_OBJECT (view->details->tree),
"drag_begin",
GTK_SIGNAL_FUNC(nautilus_tree_view_drag_begin),
view);
gtk_signal_connect (GTK_OBJECT (view->details->tree),
g_signal_connect (G_OBJECT (view->details->tree),
"drag_end",
GTK_SIGNAL_FUNC(nautilus_tree_view_drag_end),
view);
gtk_signal_connect (GTK_OBJECT (view->details->tree),
g_signal_connect (G_OBJECT (view->details->tree),
"drag_leave",
GTK_SIGNAL_FUNC(nautilus_tree_view_drag_leave),
view);
gtk_signal_connect (GTK_OBJECT (view->details->tree),
g_signal_connect (G_OBJECT (view->details->tree),
"drag_motion",
GTK_SIGNAL_FUNC(nautilus_tree_view_drag_motion),
view);
gtk_signal_connect (GTK_OBJECT (view->details->tree),
g_signal_connect (G_OBJECT (view->details->tree),
"drag_drop",
GTK_SIGNAL_FUNC(nautilus_tree_view_drag_drop),
view);
gtk_signal_connect (GTK_OBJECT (view->details->tree),
g_signal_connect (G_OBJECT (view->details->tree),
"drag_data_received",
GTK_SIGNAL_FUNC(nautilus_tree_view_drag_data_received),
view);
gtk_signal_connect (GTK_OBJECT (view->details->tree),
g_signal_connect (G_OBJECT (view->details->tree),
"drag_data_get",
GTK_SIGNAL_FUNC(nautilus_tree_view_drag_data_get),
view);
/* override the default handlers */
gtk_signal_connect (GTK_OBJECT (view->details->tree),
g_signal_connect (G_OBJECT (view->details->tree),
"button-press-event",
GTK_SIGNAL_FUNC (nautilus_tree_view_button_press),
NULL);
gtk_signal_connect (GTK_OBJECT (view->details->tree),
g_signal_connect (G_OBJECT (view->details->tree),
"button-release-event",
GTK_SIGNAL_FUNC (nautilus_tree_view_button_release),
NULL);
gtk_signal_connect (GTK_OBJECT (view->details->tree),
g_signal_connect (G_OBJECT (view->details->tree),
"motion-notify-event",
GTK_SIGNAL_FUNC (nautilus_tree_view_motion_notify),
NULL);
gtk_signal_connect (GTK_OBJECT (view->details->tree), "realize",
g_signal_connect (G_OBJECT (view->details->tree), "realize",
tree_view_realize_callback, view);
}
......
......@@ -783,19 +783,19 @@ nautilus_tree_view_load_from_filesystem (NautilusTreeView *view)
nautilus_tree_view_model_node_changed_callback,
view);
gtk_signal_connect (GTK_OBJECT (view->details->model),
g_signal_connect (G_OBJECT (view->details->model),
"node_changed",
nautilus_tree_view_model_node_changed_callback,
view);
gtk_signal_connect (GTK_OBJECT (view->details->model),
g_signal_connect (G_OBJECT (view->details->model),
"node_removed",
nautilus_tree_view_model_node_removed_callback,
view);
gtk_signal_connect (GTK_OBJECT (view->details->model),
g_signal_connect (G_OBJECT (view->details->model),
"node_being_renamed",
nautilus_tree_view_model_node_renamed_callback,
view);
gtk_signal_connect (GTK_OBJECT (view->details->model),
g_signal_connect (G_OBJECT (view->details->model),
"done_loading_children",
nautilus_tree_view_model_done_loading_callback,
view);
......@@ -946,17 +946,17 @@ create_tree (NautilusTreeView *view)
+ view->details->tree->style->font->descent));
eel_ctree_set_indent (EEL_CTREE (view->details->tree), 12);
gtk_signal_connect (GTK_OBJECT (view->details->tree),
g_signal_connect (G_OBJECT (view->details->tree),
"tree_expand",
GTK_SIGNAL_FUNC (tree_expand_callback),
view);
gtk_signal_connect (GTK_OBJECT (view->details->tree),
g_signal_connect (G_OBJECT (view->details->tree),
"tree_collapse",
GTK_SIGNAL_FUNC (tree_collapse_callback),
view);
gtk_signal_connect (GTK_OBJECT (view->details->tree),
g_signal_connect (G_OBJECT (view->details->tree),
"tree_select_row",
GTK_SIGNAL_FUNC (tree_select_row_callback),
view);
......@@ -1045,7 +1045,7 @@ nautilus_tree_view_init (NautilusTreeView *view)
view->details->show_non_directories =
! eel_preferences_get_boolean (NAUTILUS_PREFERENCES_TREE_SHOW_ONLY_DIRECTORIES);
gtk_signal_connect (GTK_OBJECT (view),
g_signal_connect (G_OBJECT (view),
"load_location",
GTK_SIGNAL_FUNC (tree_load_location_callback),
view);
......@@ -1061,11 +1061,11 @@ nautilus_tree_view_init (NautilusTreeView *view)
nautilus_view_construct (NAUTILUS_VIEW (view),
view->details->scrolled_window);
gtk_signal_connect (GTK_OBJECT (view->details->scrolled_window),
g_signal_connect (G_OBJECT (view->details->scrolled_window),
"map",
tree_map_callback,
view);
gtk_signal_connect (GTK_OBJECT (view->details->scrolled_window),
g_signal_connect (G_OBJECT (view->details->scrolled_window),
"unmap",
tree_unmap_callback,
view);
......
......@@ -540,12 +540,12 @@ layout_rows (GtkWrapBox *wbox,
}
GTK_HWRAP_BOX (wbox)->request_this_height_next_time = total_height;
if (!(GTK_HWRAP_BOX (wbox)->request_stored_height )) {
gtk_signal_emit_by_name (GTK_OBJECT (wbox), "need_reallocation", NULL);
g_signal_emit_by_name (GTK_OBJECT (wbox), "need_reallocation", NULL);
GTK_HWRAP_BOX (wbox)->request_stored_height = TRUE;
}
if (total_height > area->height) {
shrink_height = total_height - area->height;
gtk_signal_emit_by_name (GTK_OBJECT (wbox), "need_reallocation", NULL);
g_signal_emit_by_name (GTK_OBJECT (wbox), "need_reallocation", NULL);
}
else
shrink_height = 0;
......
......@@ -163,17 +163,17 @@ present_authentication_dialog_nonblocking (CallbackInfo *info)
gtk_window_set_modal (GTK_WINDOW (dialog), FALSE);
gtk_signal_connect (GTK_OBJECT (dialog),
g_signal_connect (G_OBJECT (dialog),
"clicked",
GTK_SIGNAL_FUNC (authentication_dialog_button_clicked),
info);
gtk_signal_connect (GTK_OBJECT (dialog),
g_signal_connect (G_OBJECT (dialog),
"close",
GTK_SIGNAL_FUNC (authentication_dialog_closed),
info);
gtk_signal_connect (GTK_OBJECT (dialog),
g_signal_connect (G_OBJECT (dialog),
"destroy",
GTK_SIGNAL_FUNC (authentication_dialog_destroyed),
info);
......
......@@ -103,7 +103,7 @@ nautilus_bookmark_class_init (NautilusBookmarkClass *class)
G_SIGNAL_RUN_LAST,
G_STRUCT_OFFSET (NautilusBookmarkClass, appearance_changed),
NULL, NULL,
gtk_marshal_NONE__NONE,
gtk_marshal_VOID__VOID,
G_TYPE_NONE, 0);
signals[CONTENTS_CHANGED] =
......@@ -112,7 +112,7 @@ nautilus_bookmark_class_init (NautilusBookmarkClass *class)
G_SIGNAL_RUN_LAST,
G_STRUCT_OFFSET (NautilusBookmarkClass, contents_changed),
NULL, NULL,
gtk_marshal_NONE__NONE,
gtk_marshal_VOID__VOID,
G_TYPE_NONE, 0);
}
......@@ -298,7 +298,7 @@ nautilus_bookmark_set_name (NautilusBookmark *bookmark, const char *new_name)
g_free (bookmark->details->name);
bookmark->details->name = g_strdup (new_name);
gtk_signal_emit (GTK_OBJECT (bookmark), signals[APPEARANCE_CHANGED]);
g_signal_emit (G_OBJECT (bookmark), signals[APPEARANCE_CHANGED], 0);
}
static gboolean
......@@ -411,11 +411,11 @@ bookmark_file_changed_callback (NautilusFile *file, NautilusBookmark *bookmark)
}
if (should_emit_appearance_changed_signal) {
gtk_signal_emit (GTK_OBJECT (bookmark), signals[APPEARANCE_CHANGED]);
g_signal_emit (G_OBJECT (bookmark), signals[APPEARANCE_CHANGED], 0);
}
if (should_emit_contents_changed_signal) {
gtk_signal_emit (GTK_OBJECT (bookmark), signals[CONTENTS_CHANGED]);
g_signal_emit (G_OBJECT (bookmark), signals[CONTENTS_CHANGED], 0);
}
}
......@@ -495,7 +495,7 @@ nautilus_bookmark_connect_file (NautilusBookmark *bookmark)
bookmark->details->file = nautilus_file_get (bookmark->details->uri);
g_assert (!nautilus_file_is_gone (bookmark->details->file));
gtk_signal_connect (GTK_OBJECT (bookmark->details->file),
g_signal_connect (G_OBJECT (bookmark->details->file),
"changed",
G_CALLBACK (bookmark_file_changed_callback),
bookmark);
......@@ -517,7 +517,7 @@ nautilus_bookmark_new_with_icon (const char *uri, const char *name,
{
NautilusBookmark *new_bookmark;
new_bookmark = NAUTILUS_BOOKMARK (gtk_object_new (NAUTILUS_TYPE_BOOKMARK, NULL));
new_bookmark = NAUTILUS_BOOKMARK (g_object_new (NAUTILUS_TYPE_BOOKMARK, NULL));
gtk_object_ref (GTK_OBJECT (new_bookmark));
gtk_object_sink (GTK_OBJECT (new_bookmark));
......
......@@ -110,7 +110,7 @@ nautilus_connect_desktop_background_to_file_metadata (NautilusIconContainer *ico
if (GTK_WIDGET_REALIZED (icon_container)) {
desktop_background_realized (icon_container, GINT_TO_POINTER (FALSE));
} else {
gtk_signal_connect (GTK_OBJECT (icon_container), "realize", GTK_SIGNAL_FUNC (desktop_background_realized), GINT_TO_POINTER (TRUE));
g_signal_connect (G_OBJECT (icon_container), "realize", GTK_SIGNAL_FUNC (desktop_background_realized), GINT_TO_POINTER (TRUE));
}
nautilus_file_background_receive_root_window_changes (background);
......@@ -542,7 +542,7 @@ nautilus_file_background_receive_root_window_changes (EelBackground *background)
gdk_flush ();
gdk_error_trap_pop ();
gtk_signal_connect (GTK_OBJECT (background),
g_signal_connect (G_OBJECT (background),
"destroy",
GTK_SIGNAL_FUNC (desktop_background_destroyed_callback),
NULL);
......@@ -672,7 +672,7 @@ nautilus_file_update_desktop_pixmaps (EelBackground *background)
if (eel_background_is_loaded (background)) {
image_loading_done_callback (background, TRUE, GINT_TO_POINTER (FALSE));
} else {
gtk_signal_connect (GTK_OBJECT (background),
g_signal_connect (G_OBJECT (background),
"image_loading_done",
GTK_SIGNAL_FUNC (image_loading_done_callback),
GINT_TO_POINTER (TRUE));
......@@ -957,19 +957,19 @@ nautilus_connect_background_to_file_metadata (GtkWidget *widget,
/* Connect new signal handlers. */
if (file != NULL) {
gtk_signal_connect (GTK_OBJECT (background),
g_signal_connect (G_OBJECT (background),
"settings_changed",
GTK_SIGNAL_FUNC (background_changed_callback),
file);
gtk_signal_connect (GTK_OBJECT (background),
g_signal_connect (G_OBJECT (background),
"destroy",
GTK_SIGNAL_FUNC (background_destroyed_callback),
file);
gtk_signal_connect (GTK_OBJECT (background),
g_signal_connect (G_OBJECT (background),
"reset",
GTK_SIGNAL_FUNC (background_reset_callback),
file);
gtk_signal_connect (GTK_OBJECT (file),
g_signal_connect (G_OBJECT (file),
"changed",
GTK_SIGNAL_FUNC (saved_settings_changed_callback),
background);
......
......@@ -37,28 +37,10 @@ struct NautilusMetafileMonitorDetails {
static void nautilus_metafile_monitor_init (NautilusMetafileMonitor *monitor);
static void nautilus_metafile_monitor_class_init (NautilusMetafileMonitorClass *klass);
static void destroy (GtkObject *monitor);
static void corba_metafile_changed (PortableServer_Servant servant,
const Nautilus_FileNameList *file_names,
CORBA_Environment *ev);
static void corba_metafile_ready (PortableServer_Servant servant,
CORBA_Environment *ev);
EEL_BONOBO_BOILERPLATE_FULL (NautilusMetafileMonitor,
Nautilus_MetafileMonitor,
nautilus_metafile_monitor,
BONOBO_OBJECT_TYPE)
static void
nautilus_metafile_monitor_class_init (NautilusMetafileMonitorClass *klass)
{
GTK_OBJECT_CLASS (klass)->destroy = destroy;
klass->epv.metafile_changed = corba_metafile_changed;
klass->epv.metafile_ready = corba_metafile_ready;
}
Nautilus_MetafileMonitor,
nautilus_metafile_monitor,
BONOBO_OBJECT_TYPE)
static void
nautilus_metafile_monitor_init (NautilusMetafileMonitor *monitor)
......@@ -67,21 +49,21 @@ nautilus_metafile_monitor_init (NautilusMetafileMonitor *monitor)
}
static void
destroy (GtkObject *object)
finalize (GObject *object)
{
NautilusMetafileMonitor *monitor;
monitor = NAUTILUS_METAFILE_MONITOR (object);
g_free (monitor->details);
EEL_CALL_PARENT (GTK_OBJECT_CLASS, destroy, (object));
EEL_CALL_PARENT (G_OBJECT_CLASS, finalize, (object));
}
NautilusMetafileMonitor *
nautilus_metafile_monitor_new (NautilusDirectory *directory)
{
NautilusMetafileMonitor *monitor;
monitor = NAUTILUS_METAFILE_MONITOR (gtk_object_new (NAUTILUS_TYPE_METAFILE_MONITOR, NULL));
monitor = NAUTILUS_METAFILE_MONITOR (g_object_new (NAUTILUS_TYPE_METAFILE_MONITOR, NULL));
monitor->details->directory = directory;
/* The monitor is owned by the directory, so we don't ref the directory. */
return monitor;
......@@ -135,3 +117,12 @@ corba_metafile_ready (PortableServer_Servant servant,
NULL,
NULL);
}
static void
nautilus_metafile_monitor_class_init (NautilusMetafileMonitorClass *klass)
{
G_OBJECT_CLASS (klass)->finalize = finalize;
klass->epv.metafile_changed = corba_metafile_changed;
klass->epv.metafile_ready = corba_metafile_ready;
}
......@@ -91,7 +91,7 @@ nautilus_directory_class_init (NautilusDirectoryClass *klass)
G_SIGNAL_RUN_LAST,
G_STRUCT_OFFSET (NautilusDirectoryClass, files_added),
NULL, NULL,
gtk_marshal_NONE__POINTER,
gtk_marshal_VOID__POINTER,
G_TYPE_NONE, 1, GTK_TYPE_POINTER);
signals[FILES_CHANGED] =
g_signal_new ("files_changed",
......@@ -99,7 +99,7 @@ nautilus_directory_class_init (NautilusDirectoryClass *klass)
G_SIGNAL_RUN_LAST,
G_STRUCT_OFFSET (NautilusDirectoryClass, files_changed),
NULL, NULL,
gtk_marshal_NONE__POINTER,
gtk_marshal_VOID__POINTER,
G_TYPE_NONE, 1, GTK_TYPE_POINTER);
signals[DONE_LOADING] =
g_signal_new ("done_loading",
......@@ -107,7 +107,7 @@ nautilus_directory_class_init (NautilusDirectoryClass *klass)
G_SIGNAL_RUN_LAST,
G_STRUCT_OFFSET (NautilusDirectoryClass, done_loading),
NULL, NULL,
gtk_marshal_NONE__NONE,
gtk_marshal_VOID__VOID,
G_TYPE_NONE, 0);
signals[LOAD_ERROR] =
g_signal_new ("load_error",
......@@ -115,7 +115,7 @@ nautilus_directory_class_init (NautilusDirectoryClass *klass)
G_SIGNAL_RUN_LAST,
G_STRUCT_OFFSET (NautilusDirectoryClass, load_error),
NULL, NULL,
gtk_marshal_NONE__INT,
gtk_marshal_VOID__INT,
G_TYPE_NONE, 1, GTK_TYPE_INT);
klass->get_name_for_self_as_new_file = real_get_name_for_self_as_new_file;
......@@ -486,9 +486,9 @@ nautilus_directory_new (const char *uri)
g_assert (uri != NULL);
if (eel_uri_is_trash (uri)) {
directory = NAUTILUS_DIRECTORY (gtk_object_new (NAUTILUS_TYPE_TRASH_DIRECTORY, NULL));
directory = NAUTILUS_DIRECTORY (g_object_new (NAUTILUS_TYPE_TRASH_DIRECTORY, NULL));
} else {
directory = NAUTILUS_DIRECTORY (gtk_object_new (NAUTILUS_TYPE_VFS_DIRECTORY, NULL));
directory = NAUTILUS_DIRECTORY (g_object_new (NAUTILUS_TYPE_VFS_DIRECTORY, NULL));
}
gtk_object_ref (GTK_OBJECT (directory));
gtk_object_sink (GTK_OBJECT (directory));
......@@ -683,8 +683,8 @@ nautilus_directory_emit_files_added (NautilusDirectory *directory,
GList *added_files)
{
if (added_files != NULL) {
gtk_signal_emit (GTK_OBJECT (directory),