diff --git a/gfx/drivers_context/cocoa_gl_ctx.m b/gfx/drivers_context/cocoa_gl_ctx.m index 257d427372..062d30c7dc 100644 --- a/gfx/drivers_context/cocoa_gl_ctx.m +++ b/gfx/drivers_context/cocoa_gl_ctx.m @@ -43,6 +43,12 @@ #include "../../configuration.h" #include "../../verbosity.h" +#if __has_feature(objc_arc) +#define BRIDGE __bridge +#else +#define BRIDGE +#endif + #if defined(HAVE_COCOATOUCH) #define GLContextClass EAGLContext #define GLFrameworkID CFSTR("com.apple.opengles") @@ -56,12 +62,6 @@ #define UIUserInterfaceIdiomCarPlay 3 #endif -#if __has_feature(objc_arc) -#define BRIDGE __bridge -#else -#define BRIDGE -#endif - @interface EAGLContext (OSXCompat) @end @implementation EAGLContext (OSXCompat) + (void)clearCurrentContext { [EAGLContext setCurrentContext:nil]; }