Browse Source

Compatibility fix for older OSX SDKs.

tags/2021-05-28
jules 13 years ago
parent
commit
817837ad48
1 changed files with 6 additions and 0 deletions
  1. +6
    -0
      modules/juce_gui_basics/native/juce_mac_NSViewComponentPeer.mm

+ 6
- 0
modules/juce_gui_basics/native/juce_mac_NSViewComponentPeer.mm View File

@@ -233,7 +233,13 @@ public:
if (global && window != nil)
{
r = [[view superview] convertRect: r toView: nil];
#if defined (MAC_OS_X_VERSION_10_7) && MAC_OS_X_VERSION_MIN_ALLOWED >= MAC_OS_X_VERSION_10_7
r = [window convertRectToScreen: r];
#else
r.origin = [window convertBaseToScreen: r.origin];
#endif
r.origin.y = [[[NSScreen screens] objectAtIndex: 0] frame].size.height - r.origin.y - r.size.height;
}
else


Loading…
Cancel
Save