Matteo Bruni : winemac: Update the stored display settings immediately.

Alexandre Julliard julliard at winehq.org
Wed Nov 4 15:20:31 CST 2020


Module: wine
Branch: master
Commit: f2cfd63cdac27b653c99829b780de54f16058bb8
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=f2cfd63cdac27b653c99829b780de54f16058bb8

Author: Matteo Bruni <mbruni at codeweavers.com>
Date:   Mon Nov  2 19:03:09 2020 +0100

winemac: Update the stored display settings immediately.

Instead of after sending the WM_MACDRV_UPDATE_DESKTOP_RECT
message. Specifically ddraw reacts to the followup messages and
expects to get the new display rects inside the message handler.

Signed-off-by: Matteo Bruni <mbruni at codeweavers.com>
Signed-off-by: Zhiyi Zhang <zzhang at codeweavers.com>
Signed-off-by: Ken Thomases <ken at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/winemac.drv/display.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/winemac.drv/display.c b/dlls/winemac.drv/display.c
index f6390becea7..6706c88341c 100644
--- a/dlls/winemac.drv/display.c
+++ b/dlls/winemac.drv/display.c
@@ -996,6 +996,8 @@ better:
             size_t width = CGDisplayModeGetWidth(best_display_mode);
             size_t height = CGDisplayModeGetHeight(best_display_mode);
 
+            macdrv_init_display_devices(TRUE);
+
             if (best_is_original && retina_enabled)
             {
                 width *= 2;
@@ -1005,8 +1007,6 @@ better:
             SendMessageW(GetDesktopWindow(), WM_MACDRV_UPDATE_DESKTOP_RECT, mode_bpp,
                          MAKELPARAM(width, height));
             ret = DISP_CHANGE_SUCCESSFUL;
-
-            macdrv_init_display_devices(TRUE);
         }
         else
         {




More information about the wine-cvs mailing list