Ken Thomases : winemac: Extract some logic into a new function, sync_window_z_order().

Alexandre Julliard julliard at wine.codeweavers.com
Sat May 14 10:07:28 CDT 2016


Module: wine
Branch: master
Commit: 321a1511da6b1eb63cd646e1d77a8d69790d3cf3
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=321a1511da6b1eb63cd646e1d77a8d69790d3cf3

Author: Ken Thomases <ken at codeweavers.com>
Date:   Thu May 12 18:50:45 2016 -0500

winemac: Extract some logic into a new function, sync_window_z_order().

Signed-off-by: Ken Thomases <ken at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/winemac.drv/window.c | 14 ++++++++++++--
 1 file changed, 12 insertions(+), 2 deletions(-)

diff --git a/dlls/winemac.drv/window.c b/dlls/winemac.drv/window.c
index bb82927..0d6ef53 100644
--- a/dlls/winemac.drv/window.c
+++ b/dlls/winemac.drv/window.c
@@ -785,6 +785,16 @@ static void hide_window(struct macdrv_win_data *data)
 
 
 /***********************************************************************
+ *              sync_window_z_order
+ */
+static void sync_window_z_order(struct macdrv_win_data *data)
+{
+    if (data->on_screen)
+        show_window(data);
+}
+
+
+/***********************************************************************
  *              get_region_data
  *
  * Calls GetRegionData on the given region and converts the rectangle
@@ -878,8 +888,8 @@ static void sync_window_position(struct macdrv_win_data *data, UINT swp_flags, c
     TRACE("win %p/%p whole_rect %s frame %s\n", data->hwnd, data->cocoa_window,
           wine_dbgstr_rect(&data->whole_rect), wine_dbgstr_cgrect(frame));
 
-    if (data->on_screen && (!(swp_flags & SWP_NOZORDER) || (swp_flags & SWP_SHOWWINDOW)))
-        show_window(data);
+    if (!(swp_flags & SWP_NOZORDER) || (swp_flags & SWP_SHOWWINDOW))
+        sync_window_z_order(data);
 }
 
 




More information about the wine-cvs mailing list