Ubuntu

firefox rss feed chooser doesn't pick up installed apps

Reported by John Levin on 2007-05-16
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mozilla Firefox
Confirmed
Medium
firefox-3.0 (Ubuntu)
Medium
Unassigned
firefox (Ubuntu)
Medium
Unassigned

Bug Description

Binary package hint: firefox

When previewing rss feeds in firefox, there is an option to
"Subscribe to this feed using:" and a drop down menu offering firefox, some webservices and "Choose Application"
For "Choose Application" a file browser window pops up, showing the home/user directory.

Consquently, it neither gives an easy way to pick applications, nor shows those applications capable of reading rss feeds.

Ubuntu 7.04.

Changed in firefox:
assignee: nobody → mozilla-bugs
John Vivirito (gnomefreak) wrote :

What version of firefox is this on. I think i have seen this bug reported already in ubuntu and upstream, i will take a look this week.

Changed in firefox:
status: Unconfirmed → Needs Info
John Vivirito (gnomefreak) wrote :

This might be -gnome-support package problem, i will bring this up to maintainer and see what he thinks. Ther eis no upstream bug report on this one yet.

This is the Linux equivalent of bug 348808. Requesting [wanted-1.9].

Re-requesting blocking-1.9+, as it turns out this blocks bug 404434, and that already has blocking-1.9+.

Does anyone with GNOME experience have a take on how hard this would be (assuming it's possible)?

+'ing and marking as P3 which aligns with bug 404434.

IIRC, there is no direct gnome API to get such a list, though it is not very difficult to do so.
Anyways, I think first having bug 373397 landed would help making it more easily. I'll post an updated patch soon.

Data (ubuntuaddress) wrote :

I also see this "bug" in an up-to-date installation of hardy alpha 5 and firefox 3 beta 3.

I think at least an entry for the default feed reader liferea should show up there.

Changed in firefox:
status: Incomplete → Confirmed
Data (ubuntuaddress) wrote :

adding new task for firefox-3.0

firefox task -> won't fix as firefox 2 won't see any more updates afaik.

Data (ubuntuaddress) wrote :

OK, sorry for the bug spam, but obviously I cannot set the status to Won't Fix.
Someone else will have to do that!

On Thu, May 22, 2008 at 11:23:06AM -0000, Data wrote:
> OK, sorry for the bug spam, but obviously I cannot set the status to Won't Fix.
> Someone else will have to do that!
>

Doing so ...

 affects ubuntu/firefox
 status wontfix

Thanks!

 - Alexander

Changed in firefox:
status: Confirmed → Won't Fix

Alexander Sack wrote:
> On Thu, May 22, 2008 at 11:23:06AM -0000, Data wrote:
>> OK, sorry for the bug spam, but obviously I cannot set the status to Won't Fix.
>> Someone else will have to do that!
>>
>
> Doing so ...
>
> affects ubuntu/firefox
> status wontfix
>
> Thanks!
>
> - Alexander
>
>
> ** Changed in: firefox (Ubuntu)
> Status: Confirmed => Won't Fix
>
Is this still an issue with Firefox-3.0 RC1 in Hardy. I dont think we
backported RC1 to Gutsy yet but we are going to.

--
Sincerely Yours,
     John Vivirito

https://launchpad.net/~gnomefreak
https://wiki.ubuntu.com/JohnVivirito
Linux User# 414246

Data (ubuntuaddress) wrote :

It is still an issue with firefox-3.0RC1.
This is related to another bugreport complaining about firefox's inability to detect which programs are installed for which mime-types. Instead you have to select the executable from a directory by hand. Resolving that bug would also solve this one. Unfortunately I cannot find it right now...
Maybe I'll look for it later

Alexander Sack (asac) wrote :

you need the gnome-support package installed by default to get this working. maybe ffox 3.1 with its Qt backend gives a cure. However, we should forward this bug upstream.

Changed in firefox-3.0:
status: New → Triaged
Alexander Sack (asac) wrote :

this is https://bugzilla.mozilla.org/show_bug.cgi?id=397700 ... and somewhat a dupe of bug 58710 here in ubuntu. but lets keep it open.

Changed in firefox:
importance: Undecided → Unknown
status: New → Unknown
Changed in firefox:
status: Unknown → Confirmed

The Gnome API to get the list of all applications registered for a mimetype call gnome_vfs_mime_get_all_application(const char *mimetype);

The implementation could look like:

NS_IMETHODIMP
nsGnomeVFSService::GetAllAppsForMimeType(const nsACString &aMimeType,
                                      nsIGnomeVFSMimeApp** aApp)
{
   *aApps = nsnull;
   GList *apps =
    gnome_vfs_mime_get_all_application(PromiseFlatCString(aMimeType).get());

    while(apps) {
       GList *next = apps->next;
       nsGnomeVFSMimeApp *mozApp = new nsGnomeVFSMimeApp(apps->data);
       NS_ENSURE_TRUE(mozApp, NS_ERROR_OUT_OF_MEMORY);

       NS_ADDREF(apps->data = mozApp);
   }
   return NS_OK;
}

Similar to https://bugzilla.mozilla.org/show_bug.cgi?id=370380

Please try to implement a cross-desktop (xdg-* tool based?) solution.

*** Bug 370380 has been marked as a duplicate of this bug. ***

Repeating my comment from the other bug since it doesn't sound like this addresses it:

-- The list of content types can't be modified, even to add something
identified only by file extension. I just ran into this when trying to get a
.ssa file. Firefox tried to open it and couldn't (not surprising). There's no
way to add "file with extension ssa" to the content type list, and I have no
idea whatsoever whether Firefox thinks it has a mime type or is just treating
it as unknown.
-- On that subject, there's no entry for "unknown content type" (at least on my
machine). Want to tell Firefox to save all files with an unknown content type?
 Forget it.
-- There's no way to tell Firefox whether to determine content type by
extension first or by Mime type sent by the server first. I recently tried to
open a PDF file whose content type Firefox seemed to think was BIN. There was
no way to tell Firefox that the .PDF in the filename takes precedence over the
bogus Mime type sent by the server.
-- There's usually no option "open in browser". I want to tell Firefox to open
text files in Firefox. Can't do that.

Created attachment 373282
Removes file association mechanism of firefox and use xdg-open instead

Hi,

  I've made a small patch in order to progress on this issue. It removes Firefox file system associations and forces use of xdg-open. I do not think this patch is complete since it's not cross-platform, but I really think it's a good step in order to solve this problem.
  There's already a file association mechanism on a Linux Desktop environments (Gnome, Kde, Xfce, Lxde, etc, etc). xdg-open is a simple way to use it. It simplifies lifes of users, which do not have to choose their preferred software twice, it simplifies lifes of integrators, which do not have to choose the default for their distributions twice and it simplifies source code of Firefox : there's no more need to get a file association mechanism compatible with all Linux Desktop environment.

  I don't know who will be a good "requestee" to ask for a review of this patch, so I've left the field empty.

Regards,

You will have to request a review requestee for this patch to be looked at formally (and I'm not one of them).

This seems to be unreliable; the system default program name is displayed in the application pref pane but this may not be the same as what xdg-open uses. And like you said, this isn't cross platform.

Michael Ventnor : You are on the root of this problem :
* Does Firefox really needs to have its own application pref ? Is this not the job of a desktop environment ?

  With this patch, one can also unifiy the open with/save dialog box. Instead of having "open with" vs "save file", one can make "open file/save file" which seems more consistent and unified with other "file openers" like konqueror, dolphin, nautilus, internet explorer, etc.
  Why Firefox should ask its user which software to use ? This is confusing and complicates lifes of both users, developers and packagers.

  I can make this patch cross-platform, with some #ifndef WIN32 or something similar. But is there a Firefox developer ready to apply this kind of patch ?

*** Bug 490124 has been marked as a duplicate of this bug. ***

It should be noted that in KDE 4 the Open With dialoge can be accessed via the KOpenWithDialog class. This does require linking against kdebase, though. I do not know of a universal KDE / Gnome / *box solution, but please do not make this a Gnome-only solution. Should I ask on kde-devel or other lists how to access the Open With dialogue of the active desktop?

Thanks.

*** Bug 492104 has been marked as a duplicate of this bug. ***

When you click on "open with" firefox should list available applications using
freedesktop specification instead of letting the (newbie or power)user looking
for the right folder containing the binary. Under any windows environment when
you click on a file that the environment does not know which application it
need to be launched with, it shows the user a list of all the different
application installed on the computer. WHy does firefow under linux does not
provide this kind of thing? Plus it is trivial to list all available
application by using freedesktop specification.
Personally it is a pan in the ass but as I deal quit well with my linux system
it is ok. But for newbies coming to the opensource/linux world, it is
completely destabilizing.
Thanks

Or yeah use xdg-open!!!
http://portland.freedesktop.org/xdg-utils-1.0/xdg-open.html

the use-case of opening a file could be:
(default -but rules could be specified by user to overpass the default association)
automatically use the preferred user's application using xdg-open.
IF NO preferred association found
THEN popup dialog to the user like this http://www.amsn-project.net/w/upload/a/ab/Screenshot-4-5.jpg
giving him the choice between manual path or a list of available application (using freedesktop standard specification)
..my two cents..

(In reply to comment #15)
> the use-case of opening a file could be:
> (default -but rules could be specified by user to overpass the default
> association)
> automatically use the preferred user's application using xdg-open.
> IF NO preferred association found
> THEN popup dialog to the user like this
> http://www.amsn-project.net/w/upload/a/ab/Screenshot-4-5.jpg
> giving him the choice between manual path or a list of available application
> (using freedesktop standard specification)
> ..my two cents..

Fx already supports this and an app picker dialog, we just need to figure out how to populate it by implementing possibleLocalHandlers. (See bug 348808)

(In reply to comment #16)
> (In reply to comment #15)
> > the use-case of opening a file could be:
> > (default -but rules could be specified by user to overpass the default
> > association)
> > automatically use the preferred user's application using xdg-open.
> > IF NO preferred association found
> > THEN popup dialog to the user like this
> > http://www.amsn-project.net/w/upload/a/ab/Screenshot-4-5.jpg
> > giving him the choice between manual path or a list of available application
> > (using freedesktop standard specification)
> > ..my two cents..
>
> Fx already supports this and an app picker dialog, we just need to figure out
> how to populate it by implementing possibleLocalHandlers. (See bug 348808)

Moving to GVFS and GIO will make this easy. I'm hoping to do that (plus a bump to GTK 2.14) in the Firefox 3.next timeframe.

(In reply to comment #16)
> (In reply to comment #15)
> > the use-case of opening a file could be:
> > (default -but rules could be specified by user to overpass the default
> > association)
> > automatically use the preferred user's application using xdg-open.
> > IF NO preferred association found
> > THEN popup dialog to the user like this
> > http://www.amsn-project.net/w/upload/a/ab/Screenshot-4-5.jpg
> > giving him the choice between manual path or a list of available application
> > (using freedesktop standard specification)
> > ..my two cents..
>
> Fx already supports this and an app picker dialog, we just need to figure out
> how to populate it by implementing possibleLocalHandlers. (See bug 348808)

You means in the dev branch, it is not released yet.right?

And to Micheal, what is "Firefox 3.next timeframe."? 3.5 ?

thx

*** Bug 428382 has been marked as a duplicate of this bug. ***

The app picker has been in since 3.0. We have two open bugs related to implementing the functionality on OSX and Linux, this bug and bug 397699. Once we have possibleLocalHandlers implemented, the app picker should "just work".

And does Fx will use by default the default application setting up in the desktop user like with xdg-open?

(In reply to comment #21)
> And does Fx will use by default the default application setting up in the
> desktop user like with xdg-open?

That may be a different bug. This bug is related to ease of use in choosing an alternative, non-default application. (In that we offer an alternative to the file picker dialog.) If there's a problem on Linux with Fx sending downloaded content to default handlers or if that functionality can be improved, we should spin off a different bug or (if applicable) re-open one of the dupes.

(In reply to comment #22)
> (In reply to comment #21)
> > And does Fx will use by default the default application setting up in the
> > desktop user like with xdg-open?
>
> That may be a different bug. This bug is related to ease of use in choosing an
> alternative, non-default application. (In that we offer an alternative to the
> file picker dialog.) If there's a problem on Linux with Fx sending downloaded
> content to default handlers or if that functionality can be improved, we should
> spin off a different bug or (if applicable) re-open one of the dupes.

(Also - this bug relates to choosing the default handler in prefs, as it's called up there too.)

(The advantage of the implementation in my link is that it let the power-user to choose his local executable with an url.)

Ok I searched and did not find. So here is a new entry for the second part of my request an automaticaly call to default preferred user application [url=https://bugzilla.mozilla.org/show_bug.cgi?id=492276] bug 492276[/url]
(the first one was: choose file => choose application)

*** Bug 464062 has been marked as a duplicate of this bug. ***

(In reply to comment #14)
> Plus it is trivial to list all available application by using freedesktop specification.
> [...]
> Or yeah use xdg-open!!!
> http://portland.freedesktop.org/xdg-utils-1.0/xdg-open.html

Whereas there is a FreeDesktop specification to retrieve the default application for a MIME type (xdg-open is one of the result), there is no FreeDesktop specification to retrieve the list of all registered applications for a MIME type (xdg-mime doesn't do that if you look at the man).

Considering the archives on <email address hidden>, you'll see that there is no consensus on this, particularly on the way to deal with priorities of one application above the others (the preferred order of applications to handle a MIME type if you prefer).

I send you to http://lists.freedesktop.org/archives/xdg/2008-January/thread.html and the thread titled 'Default Program | File Association' to see what I mean (followed in February). I also send you to the FreeDesktop specifications page to see that there is nothing on this in current drafts: http://www.freedesktop.org/wiki/Specifications/. Don't hesitate to correct me if I'm wrong.

To be clear, I'm not saying this bug could not be solved, I'm saying it could not easily be done in a cross desktop way until there is no FreeDesktop consensus on this point.

If there is no freedesktop.org spec for calling the Open With... dialogue, then call the Gnome dialogue as default with an about:config option to use the KDE or other dialogue instead.

(In reply to comment #27)
> If there is no freedesktop.org spec for calling the Open With... dialogue, then
> call the Gnome dialogue as default with an about:config option to use the KDE
> or other dialogue instead.

Whereas there is such a dialog in KDE (KOpenWithDialog), there is no such thing yet in Gnome. The 'Open with…' dialog is hardwired in Nautilus (libnautilus). It's why it's not so simple.

The other problem is that you cannot wish that Firefox has a different behavior in Gnome and in KDE. There is a Linux packaging, not a Desktop packaging.

A possible way would be to put in firefox-gnome-support, and the equivalent for KDE, until there is a FreeDesktop spec, but it's no more upstream in this case.

I do not get at all what the discussion is about. We have support for finding the handler for an app at the moment using the gvfs interface. Just extend that interface to work with multiple applications and pipe the result into the app chooser. I posted how we could do that. There might be no standard, but why care? If there will be a standard it is most likley that it will go into the gvfs interface, so we do not even have to update the code after a proper standard has been established.

(In reply to comment #29)
> I do not get at all what the discussion is about. We have support for finding
> the handler for an app at the moment using the gvfs interface. Just extend that
> interface to work with multiple applications and pipe the result into the app
> chooser. I posted how we could do that. There might be no standard, but why
> care? If there will be a standard it is most likley that it will go into the
> gvfs interface, so we do not even have to update the code after a proper
> standard has been established.

You're right. We need a solution and cannot wait for standardization. But, this does not prevent us to plan for what must be realized on this subject from a short to longer term.

A quick solution:
-----------------
Develop specific and separate 'Open with…' implementation for Firefox for GTK desktops (Gnome & XFCE) and Qt ones (KDE).

The way to do this, for GTK, is as you said Clemens to use the Gnome library. GnomeVFS is now deprecated and GIO must be preferred. But we find the same methods (http://library.gnome.org/devel/gio/stable/GAppInfo.html#g-app-info-get-all) and your code could easily adapted.

The cons is that we have different implementations for Gnome/XFCE and KDE. Does Firefox can handle that, technically and formally? If not, those dev cannot be done upstream and must be made on firefox-gnome-support for instance.

The other con is that it will duplicate the code to produce an 'Open with…' dialog. Indeed, this code is already present in Nautilus. But this duplication is already done in existing Gnome apps.

The medium term plan:
------------------------

It would be great if Gnome dev, and specifically Nautilus ones, could extract the 'Open with…' code from Nautilus to be used externally. Good for Firefox and for all other application that need this code. Some talks about this here:http://markmail.org/message/mcarb3i4gg5hcvm3#query:+page:1+mid:qxaeqv22o3pkzgvx+state:results.

The long term plan:
-------------------

A FreeDesktop specification, standardizing the way to get the list of all applications registered for a mime-type and to open an 'Open with…' dialog would greatly simplify the work. An evolution of xdg-mime to get that list and not only the default application like now could be a way.

What do you think about this?

I do not understand why people are bringing up GNOME vs. KDE again and again here. We do support only GNOME at this time, and we're trying to use freedesktop where possible. There is no KDE support yet in Mozilla apps, and as much as I'd like to have it, we should not concern us with supporting something when the base for it isn't supported.
If it's easily enough possible, let's support the GNOME way now, and let's care about freedesktop when it has something for it, and about KDE integration once we have any base work for it in Mozilla code (this is not the bug for doing that base work).

I agree that we have first to correct the bug for Gnome. But this is not simply supporting or not KDE. I explain myself.

First point, the bug report is about Linux in general. Final users don't care if Firefox has only Gnome support, they want something that works under Linux cause there is a Linux build. It brings me to my second point.

We need to know if it's technically possible to distinguish the desktop the user is using. If something for Gnome is made, it could simply break this dialog under KDE if we can't detect the desktop environment. Indeed, if we call the Gnome API (GIO) in this case, it is not intended to be embedded in KDE, and this call will simply fail and break the dialog. It's not acceptable.

So can we detect easily in Firefox the desktop environment of the user to set a correction for Gnome in a first time that doesn't break KDE?

(In reply to comment #32)
> So can we detect easily in Firefox the desktop environment of the user to set a
> correction for Gnome in a first time that doesn't break KDE?

No, and we don't want to and don't need to. We call the GTK file and print dialogs, we're using GNOME stuff in multiple places, we are using theming from GTK, we don't do anything to even care if KDE is there or not, and the solution for this bug should also just ignore the fact. We don't run without GNOME libraries in any case, and there are no immediate plans to change that.

Ok. Thanks for this clarification.

Note : The bug Robert Kaiser is speaking of seems to be bug 140751

Robert Kaiser (In reply to comment #35)
> Note : The bug Robert Kaiser is speaking of seems to be bug 140751

Yes, already seen that and also this thread on Launchpad : https://bugs.launchpad.net/ubuntu/+source/firefox-3.0/+bug/220798 speaking of a malfunction of the applications preference tabs under KDE without the firefox-gnome-support package installed. It is why I care about that sort of thing. But, Robert Kaiser pointed that it is not the priority, so it's ok. One thing at a time.

Note that I'm a big KDE fan and user myself, but we need to stick with the way of things we have at Mozilla right now, and it's better to get one solution right (in Mozilla terms this needs to be the GNOME/GTK one) and only then work on improving it for others (like KDE) as well, in a new bug, and that might need some more general support code on a higher level than download file handling as well - but that's something to look at in a followup bug.

Let's first work constructively to come up with a solution on the GNOME/GTK terms Mozilla is already bound to (esp. as we already know that a really generic solution isn't possible at this moment, this is the next best thing for now).

Even as a KDE user, I agree that Firefox should code the support for Gnome. Firefox ignores everything KDE at the moment (such as File Chooser dialogues) and this is expected. Yes, it is annoying, but it is expected.

I'm also convince of this. I'm perfectly agree with you. I'm just quite new on this and I'm asking to get a clear view of the impacts of such a dev. It's know clear for me that we deal before with Gnome, will see in the future for KDE. A unified FreedDesktop spec would be a good way to alleviate the port of code from one to the other, but it's another debate.

New question now. About look-and-feel of this application selector dialog. Does it must stick with the native Gnome (or Nautilus in this case (attachment hereunder)) look-and-feel or does it must follow the Mozilla guidelines (https://wiki.mozilla.org/ContentHandling:User_Interface/Proposed_UI2) and what has made Jim Mathies on the subject for Windows (https://bug348808.bugzilla.mozilla.org/attachment.cgi?id=271748)?

Created attachment 394231
Nautilus 'open with…' dialog screenshot (french UI)

(In reply to comment #40)
> Created an attachment (id=394231) [details]
> Nautilus 'open with…' dialog screenshot (french UI)

Which is what the patch in attachment 314945 from bug 428382 (dupe of this one now) was implementing.

(In reply to comment #39)
> New question now. About look-and-feel of this application selector dialog.

I think we'd need the input of the Mozilla UI team for a firm decision on that (though I expect them to prefer not creating a Linux-specific dialog).
What we can do without them is getting the backend right to get the information we want from GNOME and feed it to the interfaces that are already there from all I know.
And I think that's what we should stick to in this bug, any UI change following this or extending functionality e.g. to get info from elsewhere should be in followup bugs.

You have a patch on this bug that is flagged for 'review?' and not assigned to any reviewer. If you want the patch to be reviewed please assign a reviewer. Thanks

Comment on attachment 373282
Removes file association mechanism of firefox and use xdg-open instead

I think Shawn is a better reviewer for this patch.

Comment on attachment 373282
Removes file association mechanism of firefox and use xdg-open instead

This wouldn't work on anything but linux but it's a cross platform file

Shawn : making it cross platform is not really difficult, since it's a tiny patch. What do you think of this approach ? If I make this patch cross-platform, would you integrate it ?

Changed in firefox:
importance: Unknown → Medium
Micah Gersten (micahg) wrote :

Sorry, this is no longer Won't Fix for the firefox source since we now use the unversioned source package.

Changed in firefox (Ubuntu):
assignee: Mozilla Bugs (mozilla-bugs) → nobody
importance: Undecided → Medium
status: Won't Fix → Triaged
Changed in firefox-3.0 (Ubuntu):
importance: Undecided → Medium

It seems this issue can be resolved using new features introduced in GTK 3.0

See: http://developer.gnome.org/gtk3/3.0/GtkAppChooser.html

and

http://developer.gnome.org/gtk3/3.0/GtkAppChooserDialog.html

The obvious first step that needs to be taken in the migration to GTK 3.0

This doesn't depend on GTK 3.0. The API's to get this information from the platform have existed already for a long time.

Is anyone interested in taking this? I'd like to get it fixed, so will take it if nobody steps up

There are bugs relating to this that dating back to 2004 I don’t think you will be treading on any toes by taking it up.

As you can see by the previous posts the issue here has been finding a way to implement this so that it can be cross platform. What are the API's you are purposing to use to implement a solution?

(In reply to comment #48)
> This doesn't depend on GTK 3.0. The API's to get this information from the
> platform have existed already for a long time.

There are API's to get this information, yes, but GTK3 comes with an application selector dialog which would make fixing this bug much easier.

I would have to agree with Michael, using the supplied GTK3 dialog is a good long term fix, it will require little maintenance once implemented, and will present the user with a consistent dialog across the desktop once other applications start to implement this generic application selector.

*** Bug 56662 has been marked as a duplicate of this bug. ***

Note that one of the dupes, (bug #56662) was filed in October 2000, and has had an unreviewed patch since August 2009. See patch details here:
https://bugs.launchpad.net/firefox/+bug/18995

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.