[Nautilus-list] Re: magic desktop URIs



On Tuesday, July 10, 2001, at 12:33  PM, Havoc Pennington wrote:

In CVS I have the desktop-vfs-module directory. This contains two
things at the moment:

 - a cheesy desktop file parser, which I am using in Nautilus to
   replace its current desktop handling code with something that works
   on non-file: URIs; I think this will need to end up cut-and-pasted
   into Nautilus for now, then eventually merged with or replaced by
   whatever George cooks up for parsing these things

 - a VFS module that simply maps magic URIs to trees of desktop files,
   we have:

      preferences:  /usr/share/control-center
      programs:     /etc/X11/applnk + /usr/share/gnome/apps
      sysconfig:    /etc/X11/sysconfig
      serverconfig: /etc/X11/serverconfig
      favorites:    ~/.gnome/apps
      starthere:    /etc/X11/starthere

Are there issues with taking up so many URI schemes? What URI schemes do we own, and which ones need to be saved for uses that come from the W3C or elsewhere?

The only issue with the Nautilus patch I think is how to deal with the cheesy desktop parser code. I think just cut-and-pasting it into Nautilus is right, probably no one else is going to use it in the immediate future anyhow. I'll try to get this patch in acceptable shape and send it in soon.

I think that's probably OK. A another approach would be to move it into eel.

For the VFS module, does this make sense for gnome-vfs or should it be
at a higher level?

I think it's OK to have this module in gnome-vfs. I think it's a similar abstraction level to the MIME -> application/component mapping machinery that's already in gnome-vfs. But given the module architecture for gnome-vfs, there's no reason it can't go elsewhere if someone has a good suggestion.

As an aside: when I write a new file into favorites:, Nautilus doesn't
rescan the directory. I guess it can't figure out that a FAM message
about ~/.gnome/apps relates to the favorites: URI. Is there a solution
to this?

The "real" solution is to add a monitoring API to gnome-vfs, and move the FAM support from Nautilus to gnome-vfs. then the favorites module can implement favorites monitoring in whatever way is appropriate.

A short-term hack is to hard-code this same logic into the nautilus-monitor.c, adding a new call to nautilus-monitor.h that checks whether a particular kind of URI can be monitored, which would return TRUE for both file URIs and all the various types of magic URIs you are introducing. This is a step in the right direction; better than spreading around the assumption about what can be monitored into other Nautilus code.

    -- Darin




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]