diff options
author | Mike Erwin <significant.bit@gmail.com> | 2016-09-27 17:16:47 +0300 |
---|---|---|
committer | Mike Erwin <significant.bit@gmail.com> | 2016-09-27 17:16:47 +0300 |
commit | 5d0de39238998da025ca2f6ee73b4c0fa0051c28 (patch) | |
tree | ea3ad69151d87620641bc61be28ba40399ad4ece /intern/ghost | |
parent | 2ebb367b0f3428b79c7517f22db9d03ac791501b (diff) |
fix Mac build for Xcode < 8
We need a long-term fix, but this will get 2.78 out the door.
Diffstat (limited to 'intern/ghost')
-rw-r--r-- | intern/ghost/intern/GHOST_SystemCocoa.mm | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/intern/ghost/intern/GHOST_SystemCocoa.mm b/intern/ghost/intern/GHOST_SystemCocoa.mm index 880cb07cad7..173f59c9c8f 100644 --- a/intern/ghost/intern/GHOST_SystemCocoa.mm +++ b/intern/ghost/intern/GHOST_SystemCocoa.mm @@ -283,7 +283,17 @@ extern "C" int GHOST_HACK_getFirstFile(char buf[FIRSTFILEBUFLG]) * CocoaAppDelegate * ObjC object to capture applicationShouldTerminate, and send quit event **/ +#if defined(__clang_major__) && __clang_major__ <= 7 +/* FIXME(merwin & Juicyfruit): long-term fix for proper protocol to use + * merwin thinks NSApplicationDelegate is the correct protocol here. Has been around since 10.6 so we should be good... what's the problem? + * https://developer.apple.com/reference/appkit/nsapplicationdelegate?language=objc + */ +@interface CocoaAppDelegate : NSObject <NSFileManagerDelegate> { +#else +/* for Xcode 8 */ @interface CocoaAppDelegate : NSObject <NSApplicationDelegate> { +#endif + GHOST_SystemCocoa *systemCocoa; } - (void)setSystemCocoa:(GHOST_SystemCocoa *)sysCocoa; |