X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/35f95708e3aee076d779ba31c6b871afb5c50daf..1c2704fe7b25f8f0b1f92b33280adc3c63d2dcab:/src/osx/cocoa/nonownedwnd.mm diff --git a/src/osx/cocoa/nonownedwnd.mm b/src/osx/cocoa/nonownedwnd.mm index 3901a71c69..9e79c6a458 100644 --- a/src/osx/cocoa/nonownedwnd.mm +++ b/src/osx/cocoa/nonownedwnd.mm @@ -4,7 +4,6 @@ // Author: DavidStefan Csomor // Modified by: // Created: 2008-06-20 -// RCS-ID: $Id$ // Copyright: (c) Stefan Csomor // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// @@ -659,7 +658,7 @@ long style, long extraStyle, const wxString& WXUNUSED(name) ) // If the parent is modal, windows with wxFRAME_FLOAT_ON_PARENT style need // to be in kCGUtilityWindowLevel and not kCGFloatingWindowLevel to stay // above the parent. - wxDialog * const parentDialog = wxDynamicCast(parent, wxDialog); + wxDialog * const parentDialog = parent == NULL ? NULL : wxDynamicCast(parent->MacGetTopLevelWindow(), wxDialog); if (parentDialog && parentDialog->IsModal()) { if (level == kCGFloatingWindowLevel) @@ -1035,16 +1034,6 @@ void wxNonOwnedWindowCocoaImpl::WindowToScreen( int *x, int *y ) *y = p.y; } -double wxNonOwnedWindowCocoaImpl::GetMagnificationFactor() const -{ -#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_7 - if ( [ m_macWindow respondsToSelector:@selector(backingScaleFactor) ] ) - return [m_macWindow backingScaleFactor]; - else -#endif - return 1.0; -} - bool wxNonOwnedWindowCocoaImpl::IsActive() { return [m_macWindow isKeyWindow];