[Scummvm-devel] Configuration domains

Max Horn max at quendi.de
Thu Apr 20 01:57:01 CEST 2006

Am 20.04.2006 um 10:25 schrieb Lars Persson:

> Hi!
> I just noticed that my porting was n't quite done with all the latest
> changes that have happened to the backends. Well, everything seems to
> working quite ok now, but I have one small question.
> The configuration-managment will need domains for specific  
> settings, and I
> noticed that the available domains is either set in the engines or  
> in the
> config-manager.cpp/.h.

Note quite. There exists only the app domain, the transient domain,  
and everything else -- which are game engines. No outside code can  
just add another "special" domain. If you just add a "symbian"  
domain, it'll be treated like a game domain!

> Now to my question. How and where should I add my own domain.

That's timing :). I just removed support for global domain a few days  
ago because nobody used it... <sigh>.

We can discuss re-adding port specific domains, but this time,  
differently. We can designate some domains as "special" in the config  
manager, i.e. they won't be added to the list of games domains.  
However, code will have to specifically query these domains to access  
them, no overriding via the game domains -- else we get into a  
"precedence hell" (if a key is present in three global domains, which  
value to use? If the key value is *set*, where to store it?, etc.).

> I would like to have a config domain called symbian for Symbian  
> specific
> configurations, such as key settings etc, and I would guess that if  
> every
> port would add its own domain in the config-manager files, it would  
> become
> quite clumsy in the end.

How many people move a single config file between multiple computers  
with different OSes all the time, I wonder? I'd not worry about those  
much, really.

> All comments are welcome. Right now I am adding my keysettings in the
> application domain, but don't think that is appropriate in the long  
> run.

Why exactly do you think that? (This is not a rhetoric question)


More information about the Scummvm-devel mailing list