From: Robert Roebling Date: Sun, 31 Oct 2004 14:59:11 +0000 (+0000) Subject: Small change to ease Mac transition to common X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/53fa663af1aca481d637a8277511a8397e34d02a?ds=inline Small change to ease Mac transition to common native data printing code later. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@30203 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/include/wx/cmndata.h b/include/wx/cmndata.h index b108d557ac..d495c8d63c 100644 --- a/include/wx/cmndata.h +++ b/include/wx/cmndata.h @@ -216,13 +216,12 @@ public: void SetFilename( const wxString &filename ) { m_filename = filename; } void operator=(const wxPrintData& data); - - wxPrintNativeDataBase *GetNativeData() const { return m_nativeData; } -#if defined(__WXMAC__) + // Convert between wxPrintData and native data void ConvertToNative(); void ConvertFromNative(); -#endif + // Holds the native print data + wxPrintNativeDataBase *GetNativeData() const { return m_nativeData; } public: #if defined(__WXMAC__) diff --git a/src/common/cmndata.cpp b/src/common/cmndata.cpp index a37373c110..ae0caedd0c 100644 --- a/src/common/cmndata.cpp +++ b/src/common/cmndata.cpp @@ -205,17 +205,23 @@ wxPrintData::~wxPrintData() } -#ifdef __WXMAC__ void wxPrintData::ConvertToNative() { +#ifdef __WXMAC__ m_nativePrintData->TransferFrom( this ) ; +#else + m_nativeData->TransferFrom( *this ) ; +#endif } void wxPrintData::ConvertFromNative() { +#ifdef __WXMAC__ m_nativePrintData->TransferTo( this ) ; -} +#else + m_nativeData->TransferTo( *this ) ; #endif +} void wxPrintData::operator=(const wxPrintData& data) {