supporting failed data conversions
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@49037 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -283,7 +283,8 @@ void wxDataObject::AddToPasteboard( void * pb, int itemID )
|
|||||||
{
|
{
|
||||||
// empty the buffer because in some case GetDataHere does not fill buf
|
// empty the buffer because in some case GetDataHere does not fill buf
|
||||||
memset( buf, 0, sz );
|
memset( buf, 0, sz );
|
||||||
GetDataHere( array[ i ], buf );
|
if ( GetDataHere( array[ i ], buf ) )
|
||||||
|
{
|
||||||
int counter = 1 ;
|
int counter = 1 ;
|
||||||
if ( thisFormat.GetType() == wxDF_FILENAME )
|
if ( thisFormat.GetType() == wxDF_FILENAME )
|
||||||
{
|
{
|
||||||
@@ -316,6 +317,7 @@ void wxDataObject::AddToPasteboard( void * pb, int itemID )
|
|||||||
(CFStringRef) thisFormat.GetFormatId() , data, kPasteboardFlavorNoFlags);
|
(CFStringRef) thisFormat.GetFormatId() , data, kPasteboardFlavorNoFlags);
|
||||||
CFRelease( data );
|
CFRelease( data );
|
||||||
}
|
}
|
||||||
|
}
|
||||||
free( buf );
|
free( buf );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user