From 52ce55341b7fb249376c27194ae56ee8aeb40141 Mon Sep 17 00:00:00 2001 From: TingPing Date: Sun, 16 Jun 2013 16:20:06 -0300 Subject: Fix Open Data Folder on unix Mentioned in #646 --- src/fe-gtk/fe-gtk.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/src/fe-gtk/fe-gtk.c b/src/fe-gtk/fe-gtk.c index e017b9b9..28a3b1d5 100644 --- a/src/fe-gtk/fe-gtk.c +++ b/src/fe-gtk/fe-gtk.c @@ -1008,8 +1008,20 @@ fe_open_url_inner (const char *url) static void fe_open_url_locale (const char *url) { + if (url_check_word (url) == WORD_PATH) + { +#ifndef WIN32 + char *uri; + + uri = g_strconcat ("file://", url, NULL); + fe_open_url_inner (uri); + g_free (uri); +#else + fe_open_url_inner (url); +#endif + } /* the http:// part's missing, prepend it, otherwise it won't always work */ - if (strchr (url, ':') == NULL && url_check_word (url) != WORD_PATH) + else if (strchr (url, ':') == NULL) { url = g_strdup_printf ("http://%s", url); fe_open_url_inner (url); -- cgit 1.4.1