[winecfg 1.1] Implement saveConfigValue(), style changes, code cleanup, UI alignment

Dimitrie O. Paun dpaun at rogers.com
Thu Aug 28 08:06:29 CDT 2003

On August 28, 2003 06:50 am, Mike Hearn wrote:
> 2) Introduce some kind of global flag, maybe a config.h switch, maybe an
> exported variable (which is best?) that controls whether the
> configuration is read from the registry or config file. As patches are
> submitted to make Wine read the registry as well as the config file, the
> controls in winecfg would be re-enabled so people can test it. Once all
> the settings have been dual-purposed in this way, we can write a bit of
> migration code so people upgrading have their configurations copied into
> the registry, then throw the switch.

I really don't understand why we need the dual-purpose stuff. All we need
to do is:
    -- make sure we have a GUI element for all settings in ~/.wine/config
       (how far are we from having this?)
    -- have loadConfig() initialize all these elements properly
    -- have saveConfig() do the saving, being a mirror image of loadConfig()
       (can't we unify them somehow so we have only one place to
        modify to add new values? [1])
    -- when all this is done, just remove the code from

Am I missing something?

[1] Maybe it's better to have a more descriptive structure detailing 
    stuff for each value, and having generic loadConfig/saveConfig()
    methods that know how to walk said structure and do the right
    thing. This way we can easily do add all sorts of attributes to
    the configuration values and do all sort of nice things, like
    save only stuff that has been modified, automatically tie in
    the variable to the control, etc.


More information about the wine-devel mailing list