diff options
Diffstat (limited to 'osdep/macosx_compat.h')
-rw-r--r-- | osdep/macosx_compat.h | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/osdep/macosx_compat.h b/osdep/macosx_compat.h index 9775529bc6..76308c6f98 100644 --- a/osdep/macosx_compat.h +++ b/osdep/macosx_compat.h @@ -24,6 +24,31 @@ #import <Cocoa/Cocoa.h> #include "osdep/macosx_versions.h" +#if (MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_12) +typedef NSUInteger NSWindowStyleMask; +static const NSWindowStyleMask NSWindowStyleMaskClosable = NSClosableWindowMask; +static const NSWindowStyleMask NSWindowStyleMaskTitled = NSTitledWindowMask; +static const NSWindowStyleMask NSWindowStyleMaskMiniaturizable = NSMiniaturizableWindowMask; +static const NSWindowStyleMask NSWindowStyleMaskResizable = NSResizableWindowMask; +static const NSWindowStyleMask NSWindowStyleMaskBorderless = NSBorderlessWindowMask; + +static const NSEventType NSEventTypeSystemDefined = NSSystemDefined; +static const NSEventType NSEventTypeKeyDown = NSKeyDown; +static const NSEventType NSEventTypeKeyUp = NSKeyUp; + +static const NSEventMask NSEventMaskKeyDown = NSKeyDownMask; +static const NSEventMask NSEventMaskKeyUp = NSKeyUpMask; + +#if (MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_10) +typedef NSUInteger NSEventModifierFlags; +#endif + +static const NSEventModifierFlags NSEventModifierFlagShift = NSShiftKeyMask; +static const NSEventModifierFlags NSEventModifierFlagControl = NSControlKeyMask; +static const NSEventModifierFlags NSEventModifierFlagCommand = NSCommandKeyMask; +static const NSEventModifierFlags NSEventModifierFlagOption = NSAlternateKeyMask; +#endif + #if (MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_8) @interface NSArray (SubscriptingAdditions) - (id)objectAtIndexedSubscript:(NSUInteger)index; |