Re: How is Help browser started?

From: Ingo Brückl <ib_at_wupperonline.de>
Date: Sun Mar 25 2012 - 12:15:23 CEST

Hubert Figuière wrote on Sat, 24 Mar 2012 22:33:24 -0700:

> I have that patch. That's the best we can do

I'm fine with it (a few notes on it though).

> and IMHO it is already too much given the state of brokenness of some
> distro that can't get a working gtk_show_uri().

It is so easy to talk of "broken distros", but some prefer small systems only
containing the really necessary stuff (i.e. stuff that is required for
compiling and installing). There is no ill will intended with that and so far
Linux programmers were willing to support even older or smaller systems (in
contrast to other system's programmers) which made Linux that popular it is,
IMHO.

> +// we need this for systems where gtk_show_uri() is broken
> +// don't get me started.
> +// Note that is gtk_show_uri() fails but return true, then
> +// there is nothing that can be done.

// Note that _if_ gtk_show_uri() fails but _returns_ true, then

It don't really think that comment is necessary though.

> +#else
> + GError *err = NULL;
> +#if GTK_CHECK_VERSION(2,14,0)
> + if(!gtk_show_uri (NULL, url, GDK_CURRENT_TIME, &err)) {
> + fallback_open_uri(url, &err);
> + }
> + return err;
> +#elif defined(WITH_GNOMEVFS)
> + gnome_vfs_url_show (url);
> + return err;
> +#else
> + fallback_open_uri(url, &err);
> return err;
> #endif
> #endif

I'd put the three "return err;" just once between the #endifs (just as the
definition of err is done only once).

Ingo
Received on Sun Mar 25 12:49:05 2012

This archive was generated by hypermail 2.1.8 : Sun Mar 25 2012 - 12:49:05 CEST