diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/cmd/devdraw/cocoa-screen-metal.m | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/cmd/devdraw/cocoa-screen-metal.m b/src/cmd/devdraw/cocoa-screen-metal.m index 959df59b..984ede03 100644 --- a/src/cmd/devdraw/cocoa-screen-metal.m +++ b/src/cmd/devdraw/cocoa-screen-metal.m @@ -212,12 +212,19 @@ threadmain(int argc, char **argv) + (void)callsetNeedsDisplayInRect:(NSValue *)v { NSRect r; + dispatch_time_t time; r = [v rectValue]; LOG(@"callsetNeedsDisplayInRect(%g, %g, %g, %g)", r.origin.x, r.origin.y, r.size.width, r.size.height); r = [win convertRectFromBacking:r]; LOG(@"setNeedsDisplayInRect(%g, %g, %g, %g)", r.origin.x, r.origin.y, r.size.width, r.size.height); [layer setNeedsDisplayInRect:r]; + + time = dispatch_time(DISPATCH_TIME_NOW, 16 * NSEC_PER_MSEC); + dispatch_after(time, dispatch_get_main_queue(), ^(void){ + [layer setNeedsDisplayInRect:r]; + }); + [myContent enlargeLastInputRect:r]; } |