better guarding when no printing architecture exists
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@54870 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -2356,7 +2356,9 @@ public :
|
|||||||
|
|
||||||
virtual wxGraphicsContext * CreateContext( const wxWindowDC& dc);
|
virtual wxGraphicsContext * CreateContext( const wxWindowDC& dc);
|
||||||
virtual wxGraphicsContext * CreateContext( const wxMemoryDC& dc);
|
virtual wxGraphicsContext * CreateContext( const wxMemoryDC& dc);
|
||||||
|
#if wxUSE_PRINTING_ARCHITECTURE
|
||||||
virtual wxGraphicsContext * CreateContext( const wxPrinterDC& dc);
|
virtual wxGraphicsContext * CreateContext( const wxPrinterDC& dc);
|
||||||
|
#endif
|
||||||
|
|
||||||
virtual wxGraphicsContext * CreateContextFromNativeContext( void * context );
|
virtual wxGraphicsContext * CreateContextFromNativeContext( void * context );
|
||||||
|
|
||||||
@@ -2453,9 +2455,9 @@ wxGraphicsContext * wxMacCoreGraphicsRenderer::CreateContext( const wxMemoryDC&
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if wxUSE_PRINTING_ARCHITECTURE
|
||||||
wxGraphicsContext * wxMacCoreGraphicsRenderer::CreateContext( const wxPrinterDC& dc )
|
wxGraphicsContext * wxMacCoreGraphicsRenderer::CreateContext( const wxPrinterDC& dc )
|
||||||
{
|
{
|
||||||
#if wxUSE_PRINTING_ARCHITECTURE
|
|
||||||
#ifdef __WXMAC__
|
#ifdef __WXMAC__
|
||||||
const wxDCImpl* impl = dc.GetImpl();
|
const wxDCImpl* impl = dc.GetImpl();
|
||||||
wxPrinterDCImpl *print_impl = wxDynamicCast( impl, wxPrinterDCImpl );
|
wxPrinterDCImpl *print_impl = wxDynamicCast( impl, wxPrinterDCImpl );
|
||||||
@@ -2466,10 +2468,10 @@ wxGraphicsContext * wxMacCoreGraphicsRenderer::CreateContext( const wxPrinterDC&
|
|||||||
return new wxMacCoreGraphicsContext( this,
|
return new wxMacCoreGraphicsContext( this,
|
||||||
(CGContextRef)(print_impl->GetGraphicsContext()->GetNativeContext()), (wxDouble) w, (wxDouble) h );
|
(CGContextRef)(print_impl->GetGraphicsContext()->GetNativeContext()), (wxDouble) w, (wxDouble) h );
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
#endif
|
#endif
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
wxGraphicsContext * wxMacCoreGraphicsRenderer::CreateContextFromNativeContext( void * context )
|
wxGraphicsContext * wxMacCoreGraphicsRenderer::CreateContextFromNativeContext( void * context )
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user