Re: How is Help browser started?
Ingo Brückl <[email protected]> Fri, 23 Mar 2012 13:43:51 +0100
| Newsgroups | gmane.editors.abiword.user |
|---|---|
| Message-ID | <[email protected]> |
Hubert Figuière wrote on Thu, 22 Mar 2012 13:51:46 -0700: > On 22/03/12 01:32 PM, Martin Sevior wrote: >> >> Hi Larry, >> >> In the first instance abiword checks the content of the "BROWSER" >> environment variable to search for prefered installed web browser. If >> this is not set it then itterates through a list optential browsers >> and looks for each on the users system. The first one it finds it uses >> to open the help page. The list is: > [...] >> > That is the fallback. In there there gnomevfs of gvfs (build time > dependency, the later is likely present on any recent Gtk 2 build) then > it will use that and likely launch the browser defined. Well, and just in case gnomevfs of gvfs isn't present on a Gtk 2 build (guess on whose build it is missing ;-)) we should consider the attached patch which fixes the issue on both Larry Short's and my system. Any objections? Ingo
abiword.help.browser.patch
(text/x-diff, 957 B)
Index: src/af/util/xp/ut_go_file.cpp
===================================================================
--- src/af/util/xp/ut_go_file.cpp (revision 30719)
+++ src/af/util/xp/ut_go_file.cpp (working copy)
@@ -1664,7 +1664,7 @@
/* ------------------------------------------------------------------------- */
-#if !defined(TOOLKIT_GTK_ALL) && !defined(TOOLKIT_COCOA)
+#if !defined(G_OS_WIN32) && !defined(TOOLKIT_COCOA) && !defined(WITH_GNOMEVFS)
static char *
check_program (char const *prog)
{
@@ -1703,12 +1703,12 @@
return NULL;
#else
GError *err = NULL;
+#if defined(WITH_GNOMEVFS)
#if GTK_CHECK_VERSION(2,14,0)
gtk_show_uri (NULL, url, GDK_CURRENT_TIME, &err);
- return err;
-#elif defined(WITH_GNOMEVFS)
+#else
gnome_vfs_url_show (url);
- return err;
+#endif
#else
gchar *browser = NULL;
gchar *clean_url = NULL;
@@ -1772,9 +1772,9 @@
}
g_free (browser);
g_free (clean_url);
+#endif
return err;
#endif
-#endif
}
/**