forked from bartvdbraak/blender
OSX 10.6 error - hiding code behind a respondsToSelector.
This commit is contained in:
parent
13f890a26c
commit
8733150ac1
@ -921,12 +921,15 @@ NSScreen* GHOST_WindowCocoa::getScreen()
|
||||
/* called for event, when window leaves monitor to another */
|
||||
void GHOST_WindowCocoa::setNativePixelSize(void)
|
||||
{
|
||||
NSRect backingBounds = [m_openGLView convertRectToBacking:[m_openGLView bounds]];
|
||||
|
||||
GHOST_Rect rect;
|
||||
getClientBounds(rect);
|
||||
/* make sure 10.6 keeps running */
|
||||
if ([m_openGLView respondsToSelector:@selector(setWantsBestResolutionOpenGLSurface:)]) {
|
||||
NSRect backingBounds = [m_openGLView convertRectToBacking:[m_openGLView bounds]];
|
||||
|
||||
GHOST_Rect rect;
|
||||
getClientBounds(rect);
|
||||
|
||||
m_nativePixelSize = (float)backingBounds.size.width / (float)rect.getWidth();
|
||||
m_nativePixelSize = (float)backingBounds.size.width / (float)rect.getWidth();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user