Skip to content

Commit 0af529d

Browse files
authored
Merge pull request #1531 from ychin/fix-xcode8-build
Fix code to be buildable on Xcode 8 again
2 parents c147e0c + c083c5b commit 0af529d

File tree

3 files changed

+16
-0
lines changed

3 files changed

+16
-0
lines changed

src/MacVim/MMCoreTextView.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,9 @@ NS_ASSUME_NONNULL_BEGIN
8888
// NSFontChanging methods
8989
//
9090
- (void)changeFont:(nullable id)sender;
91+
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_14
9192
- (NSFontPanelModeMask)validModesForFontPanel:(NSFontPanel *)fontPanel;
93+
#endif
9294

9395
//
9496
// NSMenuItemValidation

src/MacVim/MMCoreTextView.m

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1355,13 +1355,15 @@ - (void)changeFont:(id)sender
13551355
}
13561356
}
13571357

1358+
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_14
13581359
- (NSFontPanelModeMask)validModesForFontPanel:(NSFontPanel *)fontPanel
13591360
{
13601361
// Lets the user pick only the font face / size, as other properties as not
13611362
// useful. Still enable text/document colors as these affect the preview.
13621363
// Otherwise it could just be white text on white background in the preview.
13631364
return NSFontPanelModesMaskStandardModes & (~NSFontPanelModeMaskAllEffects | NSFontPanelModeMaskTextColorEffect | NSFontPanelModeMaskDocumentColorEffect);
13641365
}
1366+
#endif
13651367

13661368
/// Specifies whether the menu item should be enabled/disabled.
13671369
- (BOOL)validateMenuItem:(NSMenuItem *)item

src/MacVim/MacVim.h

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@
4343
#ifndef MAC_OS_X_VERSION_10_14
4444
# define MAC_OS_X_VERSION_10_14 101400
4545
#endif
46+
#ifndef MAC_OS_X_VERSION_10_15
47+
# define MAC_OS_X_VERSION_10_15 101500
48+
#endif
4649
#ifndef MAC_OS_VERSION_11_0
4750
# define MAC_OS_VERSION_11_0 110000
4851
#endif
@@ -55,13 +58,19 @@
5558
#ifndef MAC_OS_VERSION_14_0
5659
# define MAC_OS_VERSION_14_0 140000
5760
#endif
61+
#ifndef MAC_OS_VERSION_15_0
62+
# define MAC_OS_VERSION_15_0 150000
63+
#endif
5864

5965
#ifndef NSAppKitVersionNumber10_10
6066
# define NSAppKitVersionNumber10_10 1343
6167
#endif
6268
#ifndef NSAppKitVersionNumber10_10_Max
6369
# define NSAppKitVersionNumber10_10_Max 1349
6470
#endif
71+
#ifndef NSAppKitVersionNumber10_11
72+
# define NSAppKitVersionNumber10_11 1404
73+
#endif
6574
#ifndef NSAppKitVersionNumber10_12
6675
# define NSAppKitVersionNumber10_12 1504
6776
#endif
@@ -74,6 +83,9 @@
7483
#ifndef NSAppKitVersionNumber10_14
7584
# define NSAppKitVersionNumber10_14 1671
7685
#endif
86+
#ifndef NSAppKitVersionNumber10_15
87+
# define NSAppKitVersionNumber10_15 1894
88+
#endif
7789
#ifndef NSAppKitVersionNumber11_0
7890
# define NSAppKitVersionNumber11_0 2022
7991
#endif

0 commit comments

Comments
 (0)