1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-25 02:04:23 +00:00

macOS: Remove macOS 10.13 preprocessor checks

The current minimum-supported Xcode (10.1) includes the macOS 10.14.1
SDK, so APIs from macOS 10.13 will always be available.
This commit is contained in:
reuk 2022-07-19 14:24:29 +01:00
parent 9712775e5b
commit 7545fbcf3e
No known key found for this signature in database
GPG key ID: FCB43929F012EE5C
5 changed files with 0 additions and 17 deletions

View file

@ -95,14 +95,12 @@ static String getOSXVersion()
{
const String systemVersionPlist ("/System/Library/CoreServices/SystemVersion.plist");
#if defined (MAC_OS_X_VERSION_10_13) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_13
if (@available (macOS 10.13, *))
{
NSError* error = nullptr;
return [NSDictionary dictionaryWithContentsOfURL: createNSURLFromFile (systemVersionPlist)
error: &error];
}
#endif
return [NSDictionary dictionaryWithContentsOfFile: juceStringToNS (systemVersionPlist)];
}();

View file

@ -29,11 +29,6 @@ static void juceFreeAccessibilityPlatformSpecificData (NSAccessibilityElement<NS
namespace juce
{
#if ! defined (MAC_OS_X_VERSION_10_13) || MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_13
using NSAccessibilityRole = NSString*;
using NSAccessibilityNotificationName = NSString*;
#endif
#define JUCE_NATIVE_ACCESSIBILITY_INCLUDED 1
//==============================================================================
@ -717,9 +712,7 @@ private:
return NO;
});
#if defined (MAC_OS_X_VERSION_10_13) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_13
addMethod (@selector (accessibilityChildrenInNavigationOrder), getAccessibilityChildren);
#endif
registerClass();
}

View file

@ -293,11 +293,7 @@ public:
[item setTag: topLevelIndex];
[item setEnabled: i.isEnabled];
#if defined (MAC_OS_X_VERSION_10_13) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_13
[item setState: i.isTicked ? NSControlStateValueOn : NSControlStateValueOff];
#else
[item setState: i.isTicked ? NSOnState : NSOffState];
#endif
[item setTarget: (id) callback];
auto* juceItem = new PopupMenu::Item (i);

View file

@ -1436,10 +1436,8 @@ public:
{
const auto type = []
{
#if defined (MAC_OS_X_VERSION_10_13) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_13
if (@available (macOS 10.13, *))
return NSPasteboardTypeFileURL;
#endif
JUCE_BEGIN_IGNORE_WARNINGS_GCC_LIKE ("-Wdeprecated-declarations")
return (NSString*) kUTTypeFileURL;

View file

@ -341,10 +341,8 @@ private:
const auto codecType = []
{
#if defined (MAC_OS_X_VERSION_10_13) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_13
if (@available (macOS 10.13, *))
return AVVideoCodecTypeJPEG;
#endif
return AVVideoCodecJPEG;
}();