}
}
+// ----------------------------------------------------------------------------
+// wxTextDataObject
+// ----------------------------------------------------------------------------
+
+#if wxUSE_UNICODE
+void wxTextDataObject::GetAllFormats(wxDataFormat *formats, wxDataObjectBase::Direction dir) const
+{
+ *formats++ = wxDataFormat( wxDF_TEXT );
+ *formats = wxDataFormat( wxDF_UNICODETEXT );
+}
+
+#endif
+
// ----------------------------------------------------------------------------
// wxFileDataObject
// ----------------------------------------------------------------------------
{
m_filenames.Empty();
- AddFile(wxString::FromAscii((char*)pBuf));
+ // only add if this is not an empty string
+ // we can therefore clear the list by just setting an empty string
+ if ( (*(char*)pBuf) != 0 )
+ AddFile(wxString::FromAscii((char*)pBuf));
return TRUE;
}