[PATCH] Symlinks to launched documents are not dereferenced



From bug 114074 [1]:

"According to discussions from #gnome, nautilus is currently supposed to
dereference symlinks to documents if it attempts to load them in another
application. For example, symlinks to html documents should cause the
target document to be opened, allowing any relative url's to work."

[1] http://bugzilla.gnome.org/show_bug.cgi?id=114074

-- 
Christian Neumair <chris gnome-de org>
Index: libnautilus-private/nautilus-program-choosing.c
===================================================================
RCS file: /cvs/gnome/nautilus/libnautilus-private/nautilus-program-choosing.c,v
retrieving revision 1.78
diff -p -u -r1.78 nautilus-program-choosing.c
--- libnautilus-private/nautilus-program-choosing.c	2 May 2005 13:44:34 -0000	1.78
+++ libnautilus-private/nautilus-program-choosing.c	22 May 2005 21:05:18 -0000
@@ -451,8 +451,10 @@ void nautilus_launch_show_file (Nautilus
 	uri = NULL;
 	if (nautilus_file_is_nautilus_link (file)) {
 		uri = nautilus_file_get_activation_uri (file);
+	} else if (nautilus_file_is_symbolic_link (file)) {
+		uri = nautilus_file_get_symbolic_link_target_uri (file);
 	}
-	
+
 	if (uri == NULL) {
 		uri = nautilus_file_get_uri (file);
 	}
@@ -685,8 +687,10 @@ nautilus_launch_application (GnomeVFSMim
 	uri = NULL;
 	if (nautilus_file_is_nautilus_link (file)) {
 		uri = nautilus_file_get_activation_uri (file);
+	} else if (nautilus_file_is_symbolic_link (file)) {
+		uri = nautilus_file_get_symbolic_link_target_uri (file);
 	}
-	
+
 	if (uri == NULL) {
 		uri = nautilus_file_get_uri (file);
 	}

Attachment: signature.asc
Description: Dies ist ein digital signierter Nachrichtenteil



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