diff options
author | Cosimo Cecchi <cosimoc@gnome.org> | 2012-10-21 21:53:58 -0400 |
---|---|---|
committer | Cosimo Cecchi <cosimoc@gnome.org> | 2012-10-23 16:10:04 -0400 |
commit | 15d056a712cf3f6935bcb95003881aea01475693 (patch) | |
tree | 97ab7ac8bbabc929bbe17c5f90527fd303bae656 /src/nautilus-notebook.c | |
parent | 515c00b72641df1b435fe17779f769958b400987 (diff) | |
download | nautilus-15d056a712cf3f6935bcb95003881aea01475693.tar.gz |
slot: restructure window slot loading
Move all the code related to loading a new slot from
nautilus-window-manage-views.c to nautilus-window-slot.c or
nautilus-window.c; then restructure loading to avoid having the view
call back into the window.
Instead, use the begin-loading and end-loading signals on the view.
Diffstat (limited to 'src/nautilus-notebook.c')
-rw-r--r-- | src/nautilus-notebook.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/nautilus-notebook.c b/src/nautilus-notebook.c index 458aacde5..aaabf8b30 100644 --- a/src/nautilus-notebook.c +++ b/src/nautilus-notebook.c @@ -29,7 +29,6 @@ #include "nautilus-notebook.h" #include "nautilus-window.h" -#include "nautilus-window-manage-views.h" #include "nautilus-window-private.h" #include "nautilus-window-slot.h" #include "nautilus-window-slot-dnd.h" @@ -291,6 +290,7 @@ nautilus_notebook_sync_tab_label (NautilusNotebook *notebook, { GtkWidget *hbox, *label; char *location_name; + GFile *location; g_return_if_fail (NAUTILUS_IS_NOTEBOOK (notebook)); g_return_if_fail (NAUTILUS_IS_WINDOW_SLOT (slot)); @@ -301,13 +301,14 @@ nautilus_notebook_sync_tab_label (NautilusNotebook *notebook, label = GTK_WIDGET (g_object_get_data (G_OBJECT (hbox), "label")); g_return_if_fail (GTK_IS_WIDGET (label)); - gtk_label_set_text (GTK_LABEL (label), slot->title); + gtk_label_set_text (GTK_LABEL (label), nautilus_window_slot_get_title (slot)); + location = nautilus_window_slot_get_location (slot); - if (slot->location != NULL) { + if (location != NULL) { /* Set the tooltip on the label's parent (the tab label hbox), * so it covers all of the tab label. */ - location_name = g_file_get_parse_name (slot->location); + location_name = g_file_get_parse_name (location); gtk_widget_set_tooltip_text (gtk_widget_get_parent (label), location_name); g_free (location_name); } else { |