]> git.saurik.com Git - wxWidgets.git/commitdiff
Compilation fixes for wxMSW in wxUSE_STL=1 build.
authorVadim Zeitlin <vadim@wxwidgets.org>
Fri, 2 Dec 2011 12:04:46 +0000 (12:04 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Fri, 2 Dec 2011 12:04:46 +0000 (12:04 +0000)
Add explicit conversions from wxString to wchar_t* as they don't happen
implicitly when wxUSE_STL=1.

Closes #13715.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69911 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/msw/graphics.cpp
src/msw/webview_ie.cpp

index f5dbc1476f9dd857cc1e233406eef9b7b73116e3..e5161c5d5bca3ca33d22dbc1e465b6d5a74e987d 100644 (file)
@@ -899,7 +899,7 @@ wxGDIPlusFontData::Init(const wxString& name,
                         const wxColour& col,
                         Unit fontUnit)
 {
-    m_font = new Font(name, size, style, fontUnit);
+    m_font = new Font(name.wc_str(), size, style, fontUnit);
 
     m_textBrush = new SolidBrush(wxColourToColor(col));
 }
index 0ba0a722daf5373fed74744625f4a1fedba41167..d6e832b6903d3702c2dd5b8c7e9e505b79de7b10 100644 (file)
@@ -698,7 +698,9 @@ void wxWebViewIE::RunScript(const wxString& javascript)
         VARIANT level;
         VariantInit(&level);
         V_VT(&level) = VT_EMPTY;
-        window->execScript(SysAllocString(javascript), SysAllocString(language), &level);
+        window->execScript(SysAllocString(javascript.wc_str()),
+                           SysAllocString(language).wc_str(),
+                           &level);
     }
     document->Release();
 }
@@ -719,7 +721,9 @@ void wxWebViewIE::RegisterHandler(wxSharedPtr<wxWebViewHandler> handler)
             wxFAIL_MSG("Could not retrive internet session");
         }
 
-        HRESULT hr = session->RegisterNameSpace(cf, CLSID_FileProtocol, handler->GetName(), 0, NULL, 0);
+        HRESULT hr = session->RegisterNameSpace(cf, CLSID_FileProtocol,
+                                                handler->GetName().wc_str(),
+                                                0, NULL, 0);
         if(FAILED(hr))
         {
             wxFAIL_MSG("Could not register protocol");