URL and application handling/registration standard

David Faure faure at kde.org
Mon Oct 22 01:30:43 PDT 2012


On Monday 22 October 2012 09:45:31 Bastien Nocera wrote:
> On Sun, 2012-10-21 at 22:58 +0200, David Faure wrote:
> > On Friday 19 October 2012 17:09:50 David Faure wrote:
> > > > Better solution yet, imho: Screw being too clever.
> > > > 
> > > >  - Have apps list protocols they support. Eg
> > > > 
> > > > Protocols=x-scheme-handler/http;x-scheme-handler/https;
> > > 
> > > Never ever do this, for the reasons above. HTTP is too complex to send
> > > all
> > > http urls to a single app.
> > 
> > Ouch, and I just found out that /usr/share/applications/firefox.desktop
> > says
> > 
> > MimeType=text/html;text/xml;application/xhtml+xml;application/vnd.mozilla.
> > xul+xml;text/mml;application/x-
> > xpinstall;x-scheme-handler/http;x-scheme-handler/https;x-scheme-handler/f
> > tp;
> > 
> > on OpenSUSE 12.1 at least.
> > (MozillaFirefox-15.0.1-2.40.1.x86_64)
> > 
> > Didn't we say no application should ever associate itself with x-scheme-
> > handler/http?
> 
> That's not what we said. We said that no non-browser applications should
> do that.

I don't like it, but it doesn't matter anymore, I have fixed my patch from 
yesterday so that x-scheme-handler doesn't have priority over KIO protocol 
handlers, if both exist.

> > This is supposed to have priority over anything else, right? (i.e. over
> > the
> > standard mechanism of launching an app based on the file contents).
> > That's fine for special protocols (magnet://, telnet:// etc.) but not for
> > HTTP...
> 
> Why not? Sniffing HTTP URLs is completely broken. It breaks one-time
> URLs.

Not if you can then give the connexion out to the app which will hande it.
But yeah this requires that the first and second app use the same VFS.

However "sending all HTTP URLs to the browser" is broken too - e.g. if it's a 
.odt you end up launching a browser just to then launch the office application.
So double-download there too (of the headers at least).

-- 
David Faure, faure at kde.org, http://www.davidfaure.fr
Working on KDE, in particular KDE Frameworks 5



More information about the xdg mailing list