From 6a199c1f5e4c320c73ce28be6480c7a9b6a13692 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Camilla=20L=C3=B6wy?= Date: Mon, 22 Oct 2018 17:47:28 +0200 Subject: [PATCH] Allow exposing only native context APIs Fixes 1349. --- include/GLFW/glfw3native.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/include/GLFW/glfw3native.h b/include/GLFW/glfw3native.h index 83d3ca44..6bddc432 100644 --- a/include/GLFW/glfw3native.h +++ b/include/GLFW/glfw3native.h @@ -81,7 +81,7 @@ extern "C" { * System headers and types *************************************************************************/ -#if defined(GLFW_EXPOSE_NATIVE_WIN32) +#if defined(GLFW_EXPOSE_NATIVE_WIN32) || defined(GLFW_EXPOSE_NATIVE_WGL) // This is a workaround for the fact that glfw3.h needs to export APIENTRY (for // example to allow applications to correctly declare a GL_ARB_debug_output // callback) but windows.h assumes no one will define APIENTRY before it does @@ -90,14 +90,14 @@ extern "C" { #undef GLFW_APIENTRY_DEFINED #endif #include -#elif defined(GLFW_EXPOSE_NATIVE_COCOA) - #include +#elif defined(GLFW_EXPOSE_NATIVE_COCOA) || defined(GLFW_EXPOSE_NATIVE_NSGL) #if defined(__OBJC__) #import #else + #include typedef void* id; #endif -#elif defined(GLFW_EXPOSE_NATIVE_X11) +#elif defined(GLFW_EXPOSE_NATIVE_X11) || defined(GLFW_EXPOSE_NATIVE_GLX) #include #include #elif defined(GLFW_EXPOSE_NATIVE_WAYLAND)