From 36f0bf00a92b15e301bb28e840a4361e0b74b123 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Camilla=20L=C3=B6wy?= Date: Fri, 8 Jul 2022 15:51:07 +0200 Subject: [PATCH] Cocoa: Fix build failure on OS X 10.11 The NSWindowCollectionBehaviorFullScreenNone enum value is missing from system headers on 10.11 despite the documentation claiming it was added in 10.7. Unfortunately Apple has taken down all API release notes for versions prior to 10.14. This fixes a build failure introduced with 98d6e8485b327288f5b53e59e6cc2267e28376bd. --- src/cocoa_window.m | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/cocoa_window.m b/src/cocoa_window.m index 527423ee..5bb1289b 100644 --- a/src/cocoa_window.m +++ b/src/cocoa_window.m @@ -31,6 +31,10 @@ #include #include +// HACK: This enum value is missing from framework headers on OS X 10.11 despite +// having been (according to documentation) added in Mac OS X 10.7 +#define NSWindowCollectionBehaviorFullScreenNone (1 << 9) + // Returns whether the cursor is in the content area of the specified window // static GLFWbool cursorInContentArea(_GLFWwindow* window)