From 9a34ea6e028adf20fb12c470e3d5aabbe9dd61c4 Mon Sep 17 00:00:00 2001 From: Alexander Larsson Date: Wed, 15 Dec 2004 11:44:41 +0000 Subject: Fill in ctrl-l dialog correctly for desktop. 2004-12-15 Alexander Larsson * src/nautilus-location-dialog.c: (nautilus_location_dialog_new): Fill in ctrl-l dialog correctly for desktop. Patch from Matthew Gatto --- src/nautilus-location-dialog.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'src/nautilus-location-dialog.c') diff --git a/src/nautilus-location-dialog.c b/src/nautilus-location-dialog.c index 843832234..2226cc243 100644 --- a/src/nautilus-location-dialog.c +++ b/src/nautilus-location-dialog.c @@ -29,7 +29,9 @@ #include #include #include +#include #include "nautilus-location-entry.h" +#include "nautilus-desktop-window.h" struct _NautilusLocationDialogDetails { GtkWidget *entry; @@ -198,7 +200,11 @@ nautilus_location_dialog_new (NautilusWindow *window) location = nautilus_window_get_location (window); if (location != NULL) { - formatted_location = eel_format_uri_for_display (location); + if(NAUTILUS_IS_DESKTOP_WINDOW (window)) { + formatted_location = nautilus_get_desktop_directory (); + } else { + formatted_location = eel_format_uri_for_display (location); + } nautilus_entry_set_text (NAUTILUS_ENTRY (NAUTILUS_LOCATION_DIALOG (dialog)->details->entry), formatted_location); gtk_editable_select_region (GTK_EDITABLE (NAUTILUS_LOCATION_DIALOG (dialog)->details->entry), 0, -1); gtk_editable_set_position (GTK_EDITABLE (NAUTILUS_LOCATION_DIALOG (dialog)->details->entry), -1); -- cgit v1.2.1