Source changes needed to get MDI support compiling on OS X Cocoa, and a explicit cast to CGImageRef so the compiler doesn't complain.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@55751 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -44,16 +44,6 @@
|
|||||||
* turning off capabilities that don't work under cocoa yet
|
* turning off capabilities that don't work under cocoa yet
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#if wxUSE_MDI
|
|
||||||
#undef wxUSE_MDI
|
|
||||||
#define wxUSE_MDI 0
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if wxUSE_MDI_ARCHITECTURE
|
|
||||||
#undef wxUSE_MDI_ARCHITECTURE
|
|
||||||
#define wxUSE_MDI_ARCHITECTURE 0
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if wxUSE_DRAG_AND_DROP
|
#if wxUSE_DRAG_AND_DROP
|
||||||
#undef wxUSE_DRAG_AND_DROP
|
#undef wxUSE_DRAG_AND_DROP
|
||||||
#define wxUSE_DRAG_AND_DROP 0
|
#define wxUSE_DRAG_AND_DROP 0
|
||||||
@@ -74,12 +64,6 @@
|
|||||||
#define wxUSE_DATAVIEWCTRL 0
|
#define wxUSE_DATAVIEWCTRL 0
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if wxUSE_DOC_VIEW_ARCHITECTURE
|
|
||||||
#undef wxUSE_DOC_VIEW_ARCHITECTURE
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#define wxUSE_DOC_VIEW_ARCHITECTURE 0
|
|
||||||
|
|
||||||
#if wxUSE_WXHTML_HELP
|
#if wxUSE_WXHTML_HELP
|
||||||
#undef wxUSE_WXHTML_HELP
|
#undef wxUSE_WXHTML_HELP
|
||||||
#endif
|
#endif
|
||||||
|
@@ -1,5 +1,3 @@
|
|||||||
#ifdef __WXMAC_CLASSIC__
|
#if __WXOSX_CARBON__
|
||||||
#include "wx/osx/classic/uma.h"
|
|
||||||
#else
|
|
||||||
#include "wx/osx/carbon/uma.h"
|
#include "wx/osx/carbon/uma.h"
|
||||||
#endif
|
#endif
|
||||||
|
@@ -50,7 +50,7 @@ static const int IDM_WINDOWTILEVERT = 4005;
|
|||||||
|
|
||||||
void UMAHighlightAndActivateWindow( WindowRef inWindowRef , bool inActivate )
|
void UMAHighlightAndActivateWindow( WindowRef inWindowRef , bool inActivate )
|
||||||
{
|
{
|
||||||
#if 1 // TODO REMOVE
|
#if wxOSX_USE_CARBON // TODO REMOVE
|
||||||
if ( inWindowRef )
|
if ( inWindowRef )
|
||||||
{
|
{
|
||||||
// bool isHighlighted = IsWindowHighlited( inWindowRef ) ;
|
// bool isHighlighted = IsWindowHighlited( inWindowRef ) ;
|
||||||
@@ -74,6 +74,8 @@ void UMAHighlightAndActivateWindow( WindowRef inWindowRef , bool inActivate )
|
|||||||
SetPort( port ) ;
|
SetPort( port ) ;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
#elif defined(wxOSX_USE_COCOA)
|
||||||
|
// TODO: implement me!
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -163,7 +163,7 @@ wxBitmap wxWindowDCImpl::DoGetAsBitmap(const wxRect *subrect) const
|
|||||||
NSBitmapImageRep *rep = [[[NSBitmapImageRep alloc] initWithFocusedViewRect: [view bounds]] retain];
|
NSBitmapImageRep *rep = [[[NSBitmapImageRep alloc] initWithFocusedViewRect: [view bounds]] retain];
|
||||||
[view unlockFocus];
|
[view unlockFocus];
|
||||||
|
|
||||||
CGImageRef cgImageRef = [rep CGImage];
|
CGImageRef cgImageRef = (CGImageRef)[rep CGImage];
|
||||||
|
|
||||||
wxBitmap bitmap(CGImageGetWidth(cgImageRef) , CGImageGetHeight(cgImageRef) );
|
wxBitmap bitmap(CGImageGetWidth(cgImageRef) , CGImageGetHeight(cgImageRef) );
|
||||||
CGRect r = CGRectMake( 0 , 0 , CGImageGetWidth(cgImageRef) , CGImageGetHeight(cgImageRef) );
|
CGRect r = CGRectMake( 0 , 0 , CGImageGetWidth(cgImageRef) , CGImageGetHeight(cgImageRef) );
|
||||||
|
Reference in New Issue
Block a user