X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/4e16881a084fda0bb6672b71dfe3c12eaa9e6a37..6842d18650b487249b4ae29d0d7e17231b24cde8:/src/common/dobjcmn.cpp diff --git a/src/common/dobjcmn.cpp b/src/common/dobjcmn.cpp index 708d9e36ba..a71231b2ae 100644 --- a/src/common/dobjcmn.cpp +++ b/src/common/dobjcmn.cpp @@ -301,9 +301,13 @@ bool wxCustomDataObject::SetData(size_t size, const void *buf) // wxTextDropTarget // ---------------------------------------------------------------------------- +// NB: we can't use "new" in ctor initializer lists because this provokes an +// internal compiler error with VC++ 5.0 (hey, even gcc compiles this!), +// so use SetDataObject() instead + wxTextDropTarget::wxTextDropTarget() - : wxDropTarget(new wxTextDataObject) { + SetDataObject(new wxTextDataObject); } wxDragResult wxTextDropTarget::OnData(wxCoord x, wxCoord y, wxDragResult def) @@ -320,8 +324,8 @@ wxDragResult wxTextDropTarget::OnData(wxCoord x, wxCoord y, wxDragResult def) // ---------------------------------------------------------------------------- wxFileDropTarget::wxFileDropTarget() - : wxDropTarget(new wxFileDataObject) { + SetDataObject(new wxFileDataObject); } wxDragResult wxFileDropTarget::OnData(wxCoord x, wxCoord y, wxDragResult def)