From 617e17b7460c821048a5a4044f50da8dc6c803c5 Mon Sep 17 00:00:00 2001 From: Stefan Csomor Date: Wed, 30 Apr 2014 06:59:42 +0000 Subject: [PATCH] supporting alpha channel correctly from clipboard, closes #16198 git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76431 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/osx/carbon/dataobj.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/osx/carbon/dataobj.cpp b/src/osx/carbon/dataobj.cpp index 2b625d0e06..758e3a7928 100644 --- a/src/osx/carbon/dataobj.cpp +++ b/src/osx/carbon/dataobj.cpp @@ -840,10 +840,7 @@ bool wxBitmapDataObject::SetData( size_t nSize, const void *pBuf ) if ( cgImageRef ) { - m_bitmap.Create( CGImageGetWidth(cgImageRef) , CGImageGetHeight(cgImageRef) ); - CGRect r = CGRectMake( 0 , 0 , CGImageGetWidth(cgImageRef) , CGImageGetHeight(cgImageRef) ); - // since our context is upside down we dont use CGContextDrawImage - wxMacDrawCGImage( (CGContextRef) m_bitmap.GetHBITMAP() , &r, cgImageRef ) ; + m_bitmap.Create( cgImageRef ); CGImageRelease(cgImageRef); cgImageRef = NULL; }