1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

macOS: Remove macOS 10.14 preprocessor checks

The current minimum-supported Xcode (10.1) includes the macOS 10.14.1
SDK, so APIs from macOS 10.14 will always be available.
This commit is contained in:
reuk 2022-07-19 14:26:49 +01:00
parent 7545fbcf3e
commit 41ef5b7fd5
No known key found for this signature in database
GPG key ID: FCB43929F012EE5C
4 changed files with 3 additions and 11 deletions

View file

@ -41,7 +41,7 @@
#import <MobileCoreServices/MobileCoreServices.h>
#include <sys/fcntl.h>
#else
#if JUCE_MODULE_AVAILABLE_juce_opengl && defined (MAC_OS_X_VERSION_10_14) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_14
#if JUCE_MODULE_AVAILABLE_juce_opengl
#define GL_SILENCE_DEPRECATION 1
#endif

View file

@ -41,12 +41,10 @@ public:
auto numComponents = (size_t) lineStride * (size_t) jmax (1, height);
# if JUCE_MAC && defined (MAC_OS_X_VERSION_10_14) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_14
// This version of the SDK intermittently requires a bit of extra space
// SDK version 10.14+ intermittently requires a bit of extra space
// at the end of the image data. This feels like something has gone
// wrong in Apple's code.
numComponents += (size_t) lineStride;
#endif
imageData->data.allocate (numComponents, clearImage);

View file

@ -455,10 +455,7 @@ private:
{
addMethod (menuItemInvokedSelector, menuItemInvoked);
addMethod (@selector (validateMenuItem:), validateMenuItem);
#if defined (MAC_OS_X_VERSION_10_14)
addProtocol (@protocol (NSMenuItemValidation));
#endif
registerClass();
}
@ -552,10 +549,7 @@ private:
addMethod (@selector (validateMenuItem:), validateMenuItem);
addProtocol (@protocol (NSMenuDelegate));
#if defined (MAC_OS_X_VERSION_10_14)
addProtocol (@protocol (NSMenuItemValidation));
#endif
registerClass();
}

View file

@ -375,7 +375,7 @@ private:
auto flags = FileBrowserComponent::openMode | FileBrowserComponent::canSelectFiles
| ([parameters allowsMultipleSelection] ? FileBrowserComponent::canSelectMultipleItems : 0);
#if (defined (MAC_OS_X_VERSION_10_14) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_14)
#if JUCE_MAC
if (@available (macOS 10.14, *))
{
if ([parameters allowsDirectories])