http://bugs.winehq.org/show_bug.cgi?id=10874
chris morgan cmorgan@mail.leather-wallet.co.uk changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |cmorgan@mail.leather- | |wallet.co.uk
--- Comment #3 from chris morgan cmorgan@mail.leather-wallet.co.uk 2008-04-07 16:08:21 --- I've get this same problem with this application and a number of others from the same publisher.
The problem is caused as a result of a WM_DISPLAYCHANGE being sent that should not be.
In windows if an application calls ChangeDisplaySettingsEx with parameters that are identical to current display settings no WM_DISPLAYCHANGE message is sent. This makes sense as the display does not change as a result of such a call.
In wine however a call to ChangeDisplaySettingsEx with parameters identical to the current display does result in a WM_DISPLAYCHANGE message being sent.
I've made a patch which fixes this problem and enables the above application to run and some others from the same publisher:
Jumpstart Advanced Field Trips Jumpstart Maths Booster
The patch has been submitted to wine-patches and is also at:
http://www.leather-wallet.co.uk/wm_display_patch.diff
The patch adds a code to track the current colour depth as a result of successive calls to ChangeDisplaySettingsEx - this will not necessarily be the same as the current screen colour depth as on X11 driver a successful call to ChangeDisplaySettingsEx changing just the current colour depth does nothing. However the display has changed from the point of view of the caller and any wine clients so a WM_DISPLAYCHANGE message should be sent.
The patch then checks that at least the colour depth, width or height of the display has changed as a result of a call to ChangeDisplaySettingsEx before allowing a WM_DISPLAYCHANGE message to be sent.
The patch includes an additional conformance/regression test so this behaviour can be verified as the correct behaviour on different versions of Windows.