Martin Pilka wrote:
Alexandre Julliard wrote:
This is getting way too complex IMO. I think having everything in the .wine/config file is much more reasonable; most people don't need that many different configurations anyway.
What we should do is take advantage of the new config file format to create a deeper configuration hierarchy. So for instance the default x11drv config is under the registry key Wine\Config\x11drv, but we could create subtrees like Wine\Config\AppDefaults\Solitaire\x11drv which would contain the Solitaire-specific config values. This is then very fast to lookup, just try AppDefaults<current module> and if not found fall back to the current method. I don't think we need regular expressions at all.
attached is the patch. i wasn't always sure i'm doing the things in the right way, so you guys can have a look before i make the real submit.
here are some explanations:
- i think we shouldn't access the wine configuration directly through
registry, but use the PROFILE_ functions instead. in addition - now, when we're trying to do some kind of redirection, it's absolutely necessary. all the parts with direct access were rewritten.
I don't think we need to export the PROFILE functions... just let the calling code check the keys under "<appname>/key" if it exists and then fallback to simply "key" if it doesn't
- i wasn't able to find out the name of windows application we're just
executing. that's why i added the win_app_exe_name variable into misc/options.c.
GetModuleFileName(NULL, buffer, sizeof(buffer)); should do...
A+