removing code for pre 10.6 systems
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77035 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -1399,11 +1399,11 @@ int wxMacKeyCodeToModifier(wxKeyCode key)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if wxOSX_USE_COCOA && MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_6
|
#if wxOSX_USE_COCOA
|
||||||
|
|
||||||
// defined in utils.mm
|
// defined in utils.mm
|
||||||
|
|
||||||
#elif wxOSX_USE_COCOA_OR_CARBON
|
#elif wxOSX_USE_CARBON
|
||||||
|
|
||||||
wxMouseState wxGetMouseState()
|
wxMouseState wxGetMouseState()
|
||||||
{
|
{
|
||||||
|
@@ -2222,14 +2222,8 @@ void wxMacCoreGraphicsContext::DrawIcon( const wxIcon &icon, wxDouble x, wxDoubl
|
|||||||
if (m_composition == wxCOMPOSITION_DEST)
|
if (m_composition == wxCOMPOSITION_DEST)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
// the carbon version must be used on 10.5, or if the SDK is 10.5
|
#if wxOSX_USE_CARBON
|
||||||
#if wxOSX_USE_CARBON || ( wxOSX_USE_COCOA && MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_6 )
|
|
||||||
#if wxOSX_USE_COCOA
|
|
||||||
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6
|
|
||||||
if ( UMAGetSystemVersion() < 0x1060 )
|
|
||||||
#endif
|
|
||||||
{
|
{
|
||||||
#endif // wxOSX_USE_COCOA
|
|
||||||
CGContextSaveGState( m_cgContext );
|
CGContextSaveGState( m_cgContext );
|
||||||
CGContextTranslateCTM( m_cgContext,(CGFloat) x ,(CGFloat) (y + h) );
|
CGContextTranslateCTM( m_cgContext,(CGFloat) x ,(CGFloat) (y + h) );
|
||||||
CGContextScaleCTM( m_cgContext, 1, -1 );
|
CGContextScaleCTM( m_cgContext, 1, -1 );
|
||||||
@@ -2237,15 +2231,10 @@ void wxMacCoreGraphicsContext::DrawIcon( const wxIcon &icon, wxDouble x, wxDoubl
|
|||||||
PlotIconRefInContext( m_cgContext , &r , kAlignNone , kTransformNone ,
|
PlotIconRefInContext( m_cgContext , &r , kAlignNone , kTransformNone ,
|
||||||
NULL , kPlotIconRefNormalFlags , icon.GetHICON() );
|
NULL , kPlotIconRefNormalFlags , icon.GetHICON() );
|
||||||
CGContextRestoreGState( m_cgContext );
|
CGContextRestoreGState( m_cgContext );
|
||||||
#if wxOSX_USE_COCOA
|
|
||||||
}
|
}
|
||||||
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6
|
|
||||||
else
|
|
||||||
#endif
|
#endif
|
||||||
#endif // wxOSX_USE_COCOA
|
|
||||||
#endif // wxOSX_USE_CARBON || ( wxOSX_USE_COCOA && MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_6 )
|
|
||||||
|
|
||||||
#if wxOSX_USE_COCOA && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6
|
#if wxOSX_USE_COCOA
|
||||||
{
|
{
|
||||||
CGRect r = CGRectMake( (CGFloat) x , (CGFloat) y , (CGFloat) w , (CGFloat) h );
|
CGRect r = CGRectMake( (CGFloat) x , (CGFloat) y , (CGFloat) w , (CGFloat) h );
|
||||||
const WX_NSImage nsImage = icon.GetNSImage();
|
const WX_NSImage nsImage = icon.GetNSImage();
|
||||||
|
@@ -140,9 +140,6 @@
|
|||||||
|
|
||||||
@interface NSApplication(MissingAppleMenuCall)
|
@interface NSApplication(MissingAppleMenuCall)
|
||||||
- (void)setAppleMenu:(NSMenu *)menu;
|
- (void)setAppleMenu:(NSMenu *)menu;
|
||||||
#if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_6
|
|
||||||
- (void)setHelpMenu:(NSMenu* )menu;
|
|
||||||
#endif
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
class wxMenuCocoaImpl : public wxMenuImpl
|
class wxMenuCocoaImpl : public wxMenuImpl
|
||||||
|
@@ -1034,18 +1034,12 @@ bool wxNonOwnedWindowCocoaImpl::ShowFullScreen(bool show, long WXUNUSED(style))
|
|||||||
data->m_formerLevel = [m_macWindow level];
|
data->m_formerLevel = [m_macWindow level];
|
||||||
data->m_formerFrame = [m_macWindow frame];
|
data->m_formerFrame = [m_macWindow frame];
|
||||||
data->m_formerStyleMask = [m_macWindow styleMask];
|
data->m_formerStyleMask = [m_macWindow styleMask];
|
||||||
#if 0
|
|
||||||
// CGDisplayCapture( kCGDirectMainDisplay );
|
|
||||||
//[m_macWindow setLevel:NSMainMenuWindowLevel+1/*CGShieldingWindowLevel()*/];
|
|
||||||
#endif
|
|
||||||
NSRect screenframe = [[NSScreen mainScreen] frame];
|
NSRect screenframe = [[NSScreen mainScreen] frame];
|
||||||
NSRect frame = NSMakeRect (0, 0, 100, 100);
|
NSRect frame = NSMakeRect (0, 0, 100, 100);
|
||||||
NSRect contentRect;
|
NSRect contentRect;
|
||||||
|
|
||||||
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6
|
|
||||||
if ( [ m_macWindow respondsToSelector:@selector(setStyleMask:) ] )
|
|
||||||
[m_macWindow setStyleMask:data->m_formerStyleMask & ~ NSResizableWindowMask];
|
[m_macWindow setStyleMask:data->m_formerStyleMask & ~ NSResizableWindowMask];
|
||||||
#endif
|
|
||||||
|
|
||||||
contentRect = [NSWindow contentRectForFrameRect: frame
|
contentRect = [NSWindow contentRectForFrameRect: frame
|
||||||
styleMask: [m_macWindow styleMask]];
|
styleMask: [m_macWindow styleMask]];
|
||||||
@@ -1063,16 +1057,10 @@ bool wxNonOwnedWindowCocoaImpl::ShowFullScreen(bool show, long WXUNUSED(style))
|
|||||||
else if ( m_macFullScreenData != NULL )
|
else if ( m_macFullScreenData != NULL )
|
||||||
{
|
{
|
||||||
FullScreenData *data = (FullScreenData *) m_macFullScreenData ;
|
FullScreenData *data = (FullScreenData *) m_macFullScreenData ;
|
||||||
#if 0
|
|
||||||
// CGDisplayRelease( kCGDirectMainDisplay );
|
|
||||||
// [m_macWindow setLevel:data->m_formerLevel];
|
|
||||||
#endif
|
|
||||||
|
|
||||||
[m_macWindow setFrame:data->m_formerFrame display:YES];
|
[m_macWindow setFrame:data->m_formerFrame display:YES];
|
||||||
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6
|
|
||||||
if ( [ m_macWindow respondsToSelector:@selector(setStyleMask:) ] )
|
|
||||||
[m_macWindow setStyleMask:data->m_formerStyleMask];
|
[m_macWindow setStyleMask:data->m_formerStyleMask];
|
||||||
#endif
|
|
||||||
delete data ;
|
delete data ;
|
||||||
m_macFullScreenData = NULL ;
|
m_macFullScreenData = NULL ;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user