X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/71cc158eaabaeac51b6219a9df8eac06b96c794b..169d1d643c0ee0c90fa8e393b5298606bbb68cfd:/src/mac/carbon/dataobj.cpp diff --git a/src/mac/carbon/dataobj.cpp b/src/mac/carbon/dataobj.cpp index 4865f6f5ac..65401b5f33 100644 --- a/src/mac/carbon/dataobj.cpp +++ b/src/mac/carbon/dataobj.cpp @@ -24,12 +24,15 @@ // For compilers that support precompilation, includes "wx.h". #include "wx/wxprec.h" +#if wxUSE_DATAOBJ + #ifndef WX_PRECOMP #include "wx/intl.h" #endif #include "wx/log.h" #include "wx/dataobj.h" +#include "wx/dcmemory.h" #include "wx/mstream.h" #include "wx/image.h" #include "wx/metafile.h" @@ -251,8 +254,8 @@ wxBitmapDataObject::wxBitmapDataObject( Init(); if ( m_bitmap.Ok() ) { - m_pictHandle = wxMacCreatePicHandle( rBitmap ) ; - m_pictCreated = true ; + m_pictHandle = m_bitmap.GetBitmapData()->GetPictHandle() ; + m_pictCreated = false ; } } @@ -269,8 +272,8 @@ void wxBitmapDataObject::SetBitmap( wxBitmapDataObjectBase::SetBitmap(rBitmap); if ( m_bitmap.Ok() ) { - m_pictHandle = wxMacCreatePicHandle( rBitmap ) ; - m_pictCreated = true ; + m_pictHandle = m_bitmap.GetBitmapData()->GetPictHandle() ; + m_pictCreated = false ; } } @@ -330,3 +333,5 @@ bool wxBitmapDataObject::SetData( return m_bitmap.Ok(); } + +#endif \ No newline at end of file