Patchwork [07/11] Cocoa: Redraw the View asynchronously

login
register
mail settings
Submitter Andreas Färber
Date Dec. 13, 2009, 2:55 a.m.
Message ID <1260672941-9365-8-git-send-email-andreas.faerber@web.de>
Download mbox | patch
Permalink /patch/41012/
State New
Headers show

Comments

Andreas Färber - Dec. 13, 2009, 2:55 a.m.
Cf. http://developer.apple.com/mac/library/documentation/Cocoa/Conceptual/CocoaPerformance/Articles/CustomViews.html

Based on patch by Juha Riihimäki.

Signed-off-by: Andreas Färber <andreas.faerber@web.de>
Cc: Juha Riihimäki <juha.riihimaki@nokia.com>
Cc: Alexander Graf <alex@csgraf.de>
Cc: Mike Kronenberg <mike.kronenberg@kronenberg.org>
---
 cocoa.m |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Patch

diff --git a/cocoa.m b/cocoa.m
index dc9263a..d5f941b 100644
--- a/cocoa.m
+++ b/cocoa.m
@@ -938,7 +938,7 @@  static void cocoa_update(DisplayState *ds, int x, int y, int w, int h)
             w * [cocoaView cdx],
             h * [cocoaView cdy]);
     }
-    [cocoaView displayRect:rect];
+    [cocoaView setNeedsDisplayInRect:rect];
 }
 
 static void cocoa_resize(DisplayState *ds)