diff --git a/src/cocoa_init.m b/src/cocoa_init.m index 213e41b1..8c60bb31 100644 --- a/src/cocoa_init.m +++ b/src/cocoa_init.m @@ -36,11 +36,11 @@ #include -#if MAC_OS_X_VERSION_MIN_REQUIRED < 101000 +#if MAC_OS_X_VERSION_MAX_ALLOWED < 101000 NSAppearanceName const NSAppearanceNameVibrantLight = @"NSAppearanceNameVibrantLight"; NSAppearanceName const NSAppearanceNameVibrantDark = @"NSAppearanceNameVibrantDark"; #endif -#if MAC_OS_X_VERSION_MIN_REQUIRED < 101400 +#if MAC_OS_X_VERSION_MAX_ALLOWED < 101400 NSAppearanceName const NSAppearanceNameDarkAqua = @"NSAppearanceNameDarkAqua"; NSAppearanceName const NSAppearanceNameAccessibilityHighContrastAqua = @"NSAppearanceNameAccessibilityAqua"; NSAppearanceName const NSAppearanceNameAccessibilityHighContrastDarkAqua = @"NSAppearanceNameAccessibilityDarkAqua"; diff --git a/src/cocoa_platform.h b/src/cocoa_platform.h index 9246b4b8..84a0ace0 100644 --- a/src/cocoa_platform.h +++ b/src/cocoa_platform.h @@ -40,6 +40,7 @@ #else typedef void* id; typedef void NSAppearance; +typedef id NSString; #endif #if MAC_OS_X_VERSION_MIN_REQUIRED < 101300 diff --git a/src/cocoa_window.m b/src/cocoa_window.m index 16bd5eb3..4e32731a 100644 --- a/src/cocoa_window.m +++ b/src/cocoa_window.m @@ -1935,7 +1935,7 @@ GLFWtheme* _glfwGetThemeCocoa(_GLFWwindow* window) if (@available(macOS 10.09, *)) { - nsAppearanceToGLFWTheme([window->ns.object appearance], theme); + nsAppearanceToGLFWTheme([(NSWindow*)window->ns.object appearance], theme); } if (@available(macOS 10.14, *)) {