Ken Thomases : winemac: Leave a window in auto-display mode when it doesn' t yet have a display link.

Alexandre Julliard julliard at winehq.org
Fri Dec 8 13:51:29 CST 2017


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

Author: Ken Thomases <ken at codeweavers.com>
Date:   Fri Dec  8 02:54:07 2017 -0600

winemac: Leave a window in auto-display mode when it doesn't yet have a display link.

This fixes an issue where some windows (on some systems) would never display
their content area.  If they had a title bar, they'd just display that and
nothing else.

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

---

 dlls/winemac.drv/cocoa_window.m | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/dlls/winemac.drv/cocoa_window.m b/dlls/winemac.drv/cocoa_window.m
index 1b1d171..03a9e78 100644
--- a/dlls/winemac.drv/cocoa_window.m
+++ b/dlls/winemac.drv/cocoa_window.m
@@ -2427,6 +2427,8 @@ static CVReturn WineDisplayLinkCallback(CVDisplayLinkRef displayLink, const CVTi
                     _lastDisplayTime = now;
                 }
             }
+            else
+                [self setAutodisplay:YES];
         }
         [super setViewsNeedDisplay:value];
     }
@@ -2435,14 +2437,16 @@ static CVReturn WineDisplayLinkCallback(CVDisplayLinkRef displayLink, const CVTi
     {
         _lastDisplayTime = [[NSProcessInfo processInfo] systemUptime];
         [super display];
-        [self setAutodisplay:NO];
+        if (_lastDisplayID)
+            [self setAutodisplay:NO];
     }
 
     - (void) displayIfNeeded
     {
         _lastDisplayTime = [[NSProcessInfo processInfo] systemUptime];
         [super displayIfNeeded];
-        [self setAutodisplay:NO];
+        if (_lastDisplayID)
+            [self setAutodisplay:NO];
     }
 
     - (void) windowDidDrawContent




More information about the wine-cvs mailing list