- // reset file list
- ((wxFileDataObject*)m_dataObject)->SetData( 0 , "" ) ;
- firstFileAdded = true ;
+ HFSFlavor* theFile = (HFSFlavor*) theData ;
+ wxString name = wxMacFSSpec2MacFilename( &theFile->fileSpec ) ;
+
+ if ( !firstFileAdded )
+ {
+ // reset file list
+ fdo->SetData( 0 , "" ) ;
+ firstFileAdded = true ;
+ }
+
+ if (!name.IsEmpty())
+ fdo->AddFile( name ) ;