1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

gg: bring back native rendering on macos

This commit is contained in:
Alexander Medvednikov
2021-04-14 03:59:34 +03:00
parent 10bf974cda
commit 711e309eef
4 changed files with 126 additions and 7 deletions

View File

@@ -1,9 +1,16 @@
@implementation MyView2
int xx = 0;
// Alternative drawRect which calls a frame function with native Cocoa calls
- (void)drawRect:(NSRect)rect {
_sapp_call_frame2();
puts("drawRect()");
if (xx == 0) {
_sapp_call_init();
xx = 1;
}
_sapp_call_frame_native();
}
//- (BOOL)isOpaque {