[Xfce4-commits] <midori:master> Check if filename to open is a filename or not
Christian Dywan
noreply at xfce.org
Thu Feb 17 19:56:02 CET 2011
Updating branch refs/heads/master
to 40a6743e78ceb25027ff4e53ae854209e5ad0f7f (commit)
from f4875ceb7c0d1fc314c2e1242476a6bdeee9f940 (commit)
commit 40a6743e78ceb25027ff4e53ae854209e5ad0f7f
Author: Christian Dywan <christian at twotoasts.de>
Date: Thu Feb 17 19:38:49 2011 +0100
Check if filename to open is a filename or not
Fixes: https://bugs.launchpad.net/midori/+bug/715118
midori/sokoke.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/midori/sokoke.c b/midori/sokoke.c
index b772bab..3eb5932 100644
--- a/midori/sokoke.c
+++ b/midori/sokoke.c
@@ -401,7 +401,10 @@ sokoke_show_uri (GdkScreen* screen,
GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL,
GTK_STOCK_OPEN, GTK_RESPONSE_ACCEPT, NULL);
box = gtk_dialog_get_content_area (GTK_DIALOG (dialog));
- filename = g_filename_from_uri (uri, NULL, NULL);
+ if (g_str_has_prefix (uri, "file:///"))
+ filename = g_filename_from_uri (uri, NULL, NULL);
+ else
+ filename = g_strdup (uri);
ms = g_strdup_printf (_("Choose an application or command to open \"%s\":"),
filename);
gtk_box_pack_start (GTK_BOX (box), gtk_label_new (ms), TRUE, FALSE, 4);
More information about the Xfce4-commits
mailing list