Re: SoC idea: desktop file cache

Hi Martin,

On Fri, Mar 25, 2011 at 2:55 PM, Martin Pitt <martin pitt ubuntu com> wrote:
> Just for the record I would like to explain the approach that we have
> had in Ubuntu since December 09. It might not be too useful any more,
> but can perhaps at least give some pointers. Vincent didn't like it
> too much back then, and rightly said that it should be implemented
> using GVariant, but we never got around to this as the current system
> actually works quite well (and it also dropped out of focus).

Thanks, this is useful to hear of.

>  * Being able to ignore NoDisplay/Hide/OnlyShowIn desktop files, which
>   eliminated about half of the .desktop files.

Unfortunately I don't think we can use this approach for GNOME; we
need to do application tracking even for NoDisplay apps at least.

>  * Not having to do gettext lookups for translations (we use gettext
>   at runtime, so that we can update translations post-release without
>   having to rebuild app packages, see
> But even with
>   inline translations you'd save the lookups and reading a lot of
>   extra data, so I recommend to consider per-locale caches.

Yes, that makes sense.

> Also, I'm well aware of the corner case that this would simply ignore
> desktop files that the admin puts into /usr/share/applications/. We
> currently treat this case as "don't do that then", that's what
> /usr/local/ is for, but it's of course a small design wart of this.

We could probably just get away with declaring that broken, but this
kind of thing is already a huge mess for ISVs to figure out.  I think
you have to at least be correct and check whether the mtime on the
directory is newer than the cache, and ignore it if so - this is what
gtk+ does for the icon cache.

I'll look at your patches, though as I replied to Vincent I think we
should be fixing Gio nowadays first, and rebase gnome-menus on top.

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