X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/c9f7896861f734ce044ee8601ba2d8a6959c9d9e..cc24bf919256e8e1d317dbb8e67df6d007d641ea:/src/msw/enhmeta.cpp diff --git a/src/msw/enhmeta.cpp b/src/msw/enhmeta.cpp index 098c482469..aaf3f59857 100644 --- a/src/msw/enhmeta.cpp +++ b/src/msw/enhmeta.cpp @@ -57,7 +57,7 @@ IMPLEMENT_ABSTRACT_CLASS(wxEnhMetaFileDC, wxDC) // we must pass NULL if the string is empty to metafile functions static inline const wxChar *GetMetaFileName(const wxString& fn) - { return !fn ? (const wxChar *)NULL : (const wxChar*)fn.c_str(); } + { return !fn ? (const wxChar *)NULL : (const wxChar*)fn.wx_str(); } // ============================================================================ // implementation @@ -75,7 +75,7 @@ void wxEnhMetaFile::Init() } else // have valid file name, load metafile from it { - m_hMF = (WXHANDLE)::GetEnhMetaFile(m_filename); + m_hMF = (WXHANDLE)::GetEnhMetaFile(m_filename.fn_str()); if ( !m_hMF ) wxLogSysError(_("Failed to load metafile from file \"%s\"."), m_filename.c_str()); @@ -219,7 +219,7 @@ wxEnhMetaFileDC::wxEnhMetaFileDC(const wxString& filename, ScreenHDC hdcRef; m_hDC = (WXHDC)::CreateEnhMetaFile(hdcRef, GetMetaFileName(filename), - pRect, description); + pRect, description.wx_str()); if ( !m_hDC ) { wxLogLastError(_T("CreateEnhMetaFile"));