|
@@ -228,6 +228,12 @@ ScheduleContextUpdates(SDL_WindowData *data)
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
+ /* We still support OpenGL as long as Apple offers it, deprecated or not, so disable deprecation warnings about it. */
|
|
|
+ #ifdef __clang__
|
|
|
+ #pragma clang diagnostic push
|
|
|
+ #pragma clang diagnostic ignored "-Wdeprecated-declarations"
|
|
|
+ #endif
|
|
|
+
|
|
|
NSOpenGLContext *currentContext = [NSOpenGLContext currentContext];
|
|
|
NSMutableArray *contexts = data->nscontexts;
|
|
|
@synchronized (contexts) {
|
|
@@ -239,6 +245,10 @@ ScheduleContextUpdates(SDL_WindowData *data)
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
+ #ifdef __clang__
|
|
|
+ #pragma clang diagnostic pop
|
|
|
+ #endif
|
|
|
}
|
|
|
|
|
|
/* !!! FIXME: this should use a hint callback. */
|
|
@@ -1422,11 +1432,19 @@ Cocoa_CreateWindow(_THIS, SDL_Window * window)
|
|
|
SDLView *contentView = [[SDLView alloc] initWithFrame:rect];
|
|
|
[contentView setSDLWindow:window];
|
|
|
|
|
|
+ /* We still support OpenGL as long as Apple offers it, deprecated or not, so disable deprecation warnings about it. */
|
|
|
+ #ifdef __clang__
|
|
|
+ #pragma clang diagnostic push
|
|
|
+ #pragma clang diagnostic ignored "-Wdeprecated-declarations"
|
|
|
+ #endif
|
|
|
if (window->flags & SDL_WINDOW_ALLOW_HIGHDPI) {
|
|
|
if ([contentView respondsToSelector:@selector(setWantsBestResolutionOpenGLSurface:)]) {
|
|
|
[contentView setWantsBestResolutionOpenGLSurface:YES];
|
|
|
}
|
|
|
}
|
|
|
+ #ifdef __clang__
|
|
|
+ #pragma clang diagnostic pop
|
|
|
+ #endif
|
|
|
|
|
|
#if SDL_VIDEO_OPENGL_ES2
|
|
|
#if SDL_VIDEO_OPENGL_EGL
|