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

iOS: Remove iOS 12 preprocessor checks

The current minimum-supported Xcode (10.1) includes the iOS 12.1 SDK, so
APIs from iOS 12 will always be available.
This commit is contained in:
reuk 2022-07-19 13:59:24 +01:00
parent a22b23e335
commit 76e95d01ed
No known key found for this signature in database
GPG key ID: FCB43929F012EE5C
3 changed files with 1 additions and 5 deletions

View file

@ -28,7 +28,7 @@
#if JUCE_MAC || JUCE_IOS
#if JUCE_IOS
#if JUCE_MODULE_AVAILABLE_juce_opengl && defined (__IPHONE_12_0) && __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_12_0
#if JUCE_MODULE_AVAILABLE_juce_opengl
#define GLES_SILENCE_DEPRECATION 1
#endif

View file

@ -773,7 +773,6 @@ MultiTouchMapper<UITouch*> UIViewComponentPeer::currentTouches;
{
[super traitCollectionDidChange: previousTraitCollection];
#if defined (__IPHONE_12_0) && __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_12_0
if (@available (iOS 12.0, *))
{
const auto wasDarkModeActive = ([previousTraitCollection userInterfaceStyle] == UIUserInterfaceStyleDark);
@ -782,7 +781,6 @@ MultiTouchMapper<UITouch*> UIViewComponentPeer::currentTouches;
[[NSNotificationCenter defaultCenter] postNotificationName: UIViewComponentPeer::getDarkModeNotificationName()
object: nil];
}
#endif
}
- (BOOL) isAccessibilityElement

View file

@ -691,10 +691,8 @@ bool Desktop::canUseSemiTransparentWindows() noexcept
bool Desktop::isDarkModeActive() const
{
#if defined (__IPHONE_12_0) && __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_12_0
if (@available (iOS 12.0, *))
return [[[UIScreen mainScreen] traitCollection] userInterfaceStyle] == UIUserInterfaceStyleDark;
#endif
return false;
}