Support OSX 10.6 for fullscreen (#653)

* Disable full screen button

* Fixed disabling of fullscreen button

Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
This commit is contained in:
RH12503
2021-04-05 20:02:35 +08:00
committed by GitHub
parent 37de2075ba
commit 80fc072ad7

View File

@@ -2337,11 +2337,10 @@ struct webview_priv
size.width = width;
size.height = height;
[w->priv.window setMaxSize:size];
[w->priv.window setCollectionBehavior:NSWindowCollectionBehaviorFullScreenAuxiliary|NSWindowCollectionBehaviorFullScreenNone|NSWindowCollectionBehaviorFullScreenDisallowsTiling];
NSButton *button = [w->priv.window standardWindowButton:NSWindowZoomButton];
[button setEnabled: NO];
[button performSelectorOnMainThread:@selector(setEnabled:) withObject:NO
waitUntilDone:NO];
}
WEBVIEW_API void webview_set_fullscreen(struct webview *w, int fullscreen)