diff --git a/src/mac/carbon/dnd.cpp b/src/mac/carbon/dnd.cpp index cfe9297e3c..7ab73a19d1 100644 --- a/src/mac/carbon/dnd.cpp +++ b/src/mac/carbon/dnd.cpp @@ -211,7 +211,7 @@ bool wxDropTarget::GetData() { HFSFlavor* theFile = (HFSFlavor*) theData ; wxString name = wxMacFSSpec2MacFilename( &theFile->fileSpec ) ; - m_dataObject->SetData( format , name.Length() + 1, name ) ; + ((wxFileDataObject*)m_dataObject)->AddFile( name ) ; } else { diff --git a/src/mac/dnd.cpp b/src/mac/dnd.cpp index cfe9297e3c..7ab73a19d1 100644 --- a/src/mac/dnd.cpp +++ b/src/mac/dnd.cpp @@ -211,7 +211,7 @@ bool wxDropTarget::GetData() { HFSFlavor* theFile = (HFSFlavor*) theData ; wxString name = wxMacFSSpec2MacFilename( &theFile->fileSpec ) ; - m_dataObject->SetData( format , name.Length() + 1, name ) ; + ((wxFileDataObject*)m_dataObject)->AddFile( name ) ; } else {