Re: desktop schemas review [was: Re: GSettings migration status]
- From: Alan Cox <alan lxorguk ukuu org uk>
- To: Shaun McCance <shaunm gnome org>
- Cc: GNOME menubar gnome org, Christian Persch <chpe gnome org>, Alexander Larsson <alexl redhat com>, Desktop Development List <desktop-devel-list gnome org>
- Subject: Re: desktop schemas review [was: Re: GSettings migration status]
- Date: Wed, 7 Jul 2010 15:24:26 +0100
> A possible solution is to store paths under your home
> directory as relative paths, and when reading, assume
> any relative paths are relative to your home directory.
> Doing this with each individual application would be
> tiresome and error-prone, but it would be easy with
> a convenience API like this.
The traditional Unix way to deal with such paths is to base them
off an environment variable so
g_settings_set_relative_file(settings, key, envvar, path);
eg
g_settings_set_relative_file(settings, "mbox", "HOME", "mbox");
Then you have the fun that $HOME/mbox is a perfectly valid actual
filename so you need to know what you are looking at, or store files in a
smarter way.
Apple take this even further with removable media so that it knows about
paths on a removable device by the device name and relative path.
Alan
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]