Ken Thomases : winemac: Make some operations on Cocoa views asynchronous.
Module: wine Branch: master Commit: 733e22d0c12671848a90a2bd5d01eb7213728493 URL: http://source.winehq.org/git/wine.git/?a=commit;h=733e22d0c12671848a90a2bd5d... Author: Ken Thomases <ken(a)codeweavers.com> Date: Wed Feb 1 10:12:29 2017 -0600 winemac: Make some operations on Cocoa views asynchronous. There's no reason for them to be synchronous and this improves performance. Signed-off-by: Ken Thomases <ken(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/winemac.drv/cocoa_window.m | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dlls/winemac.drv/cocoa_window.m b/dlls/winemac.drv/cocoa_window.m index a68ba03..57587d9 100644 --- a/dlls/winemac.drv/cocoa_window.m +++ b/dlls/winemac.drv/cocoa_window.m @@ -3340,7 +3340,7 @@ void macdrv_set_view_frame(macdrv_view v, CGRect rect) if (CGRectIsNull(rect)) rect = CGRectZero; - OnMainThread(^{ + OnMainThreadAsync(^{ NSRect newFrame = NSRectFromCGRect(cgrect_mac_from_win(rect)); NSRect oldFrame = [view frame]; @@ -3387,7 +3387,7 @@ void macdrv_set_view_superview(macdrv_view v, macdrv_view s, macdrv_window w, ma if (!superview) superview = [window contentView]; - OnMainThread(^{ + OnMainThreadAsync(^{ if (superview == [view superview]) { NSArray* subviews = [superview subviews]; @@ -3430,7 +3430,7 @@ void macdrv_set_view_hidden(macdrv_view v, int hidden) NSAutoreleasePool* pool = [[NSAutoreleasePool alloc] init]; WineContentView* view = (WineContentView*)v; - OnMainThread(^{ + OnMainThreadAsync(^{ [view setHidden:hidden]; });
participants (1)
-
Alexandre Julliard