SystemParametersInfo / GetSystemMetrics

Andriy Palamarchuk apa3a at
Thu Oct 18 07:26:13 CDT 2001

By mistake I sent the response to you directly,
instead of the newsgroup.

--- Alexandre Julliard <julliard at> wrote:
> Andriy Palamarchuk <apa3a at> writes:
> > Do you mean we can keep GetSystemMetrics simple if
> we don't use all 
> > these synchronizations? Use some hardcoded values,
> maybe load from 
> > registry and that's it?
> You need the synchronizations, but this doesn't mean
> sysmetrics have
> to be more complex. All it means is that when
> something changes in
> registry or x11, the code that does the change has
> to do a
> SYSMETRICS_Set to update the sysmetrics. But the
> sysmetrics themselves
> don't need to know anything except how to get the
> initial value.
> > I don't see big difference between
> SystemParametersInfo and 
> > GetSystemMetrics data. Sometimes these are even
> the same! Example - flag 
> > SHOWSOUNDS. It can be read by GetSystemMetrics and
> read and set by 
> > SystemParametersInfo.
> Yes they are the same, that's why you can have the
> registry update
> code either in sysparams.c or in sysmetrics.c; and
> since we want to
> keep sysmetrics simple it has to be in sysparams.c.
> > The infrastructure I created is used to access and
> update SHOWSOUNDS 
> > flag. Can you suggest how to implement it in other
> way?
> The existing implementation is OK, what you need is
> to add registry
> update in sysparams.c upon SPI_SETSHOWSOUNDS, and
> add a call to
> SystemParametersInfo(SPI_GETSHOWSOUNDS) in
> SYSMETRICS_Init. You do not
> need to add any registry access in sysmetrics.c,
> everything will be
> done by SystemParametersInfo.

Ok, I see. I'll change the code and resend the patch.

One more question while we are on it.
We are going to check whether X settings correspond to
our settings only on initialization and reload
requests and are not going to do the check in "Get"
logic, right?

Andriy Palamarchuk

Do You Yahoo!?
Make a great connection at Yahoo! Personals.

More information about the wine-devel mailing list