]> git.saurik.com Git - wxWidgets.git/commitdiff
don't set CF_TEXT data in wxURLDataObject in Unicode build, this results in an assert
authorVadim Zeitlin <vadim@wxwidgets.org>
Tue, 30 Oct 2007 12:50:39 +0000 (12:50 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Tue, 30 Oct 2007 12:50:39 +0000 (12:50 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@49536 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/msw/ole/dataobj.cpp

index f57954158ad0865adfde8f1e9e71c583ae080b19..3003abdd38bf4fab236fda378e6b3461222327c8 100644 (file)
@@ -1249,11 +1249,15 @@ void wxURLDataObject::SetURL(const wxString& url)
     if ( urlMB )
     {
         const size_t len = strlen(urlMB) + 1; // size with trailing NUL
+#if !wxUSE_UNICODE
         SetData(wxDF_TEXT, len, urlMB);
+#endif
         SetData(wxDataFormat(CFSTR_SHELLURL), len, urlMB);
     }
 
+#if wxUSE_UNICODE
     SetData(wxDF_UNICODETEXT, url.length() + 1, url.wc_str());
+#endif
 }
 
 // ----------------------------------------------------------------------------