Add compilation guards for macOS 10.10 to avoid warnings
"[NSColor linkColor]" gives a compile-time warning even if we don't use it during the run-time, so check MAC_OS_X_VERSION_MAX_ALLOWED before using it.
This commit is contained in:
@@ -163,11 +163,13 @@ wxColour wxSystemSettingsNative::GetColour(wxSystemColour index)
|
|||||||
sysColor = [NSColor windowBackgroundColor];
|
sysColor = [NSColor windowBackgroundColor];
|
||||||
break;
|
break;
|
||||||
case wxSYS_COLOUR_HOTLIGHT:
|
case wxSYS_COLOUR_HOTLIGHT:
|
||||||
|
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_10
|
||||||
if ( WX_IS_MACOS_AVAILABLE(10, 10) )
|
if ( WX_IS_MACOS_AVAILABLE(10, 10) )
|
||||||
{
|
{
|
||||||
sysColor = [NSColor linkColor];
|
sysColor = [NSColor linkColor];
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
#endif
|
||||||
{
|
{
|
||||||
// OSX doesn't change color on mouse hover
|
// OSX doesn't change color on mouse hover
|
||||||
sysColor = [NSColor controlTextColor];
|
sysColor = [NSColor controlTextColor];
|
||||||
|
Reference in New Issue
Block a user