From: <man...@us...> - 2015-06-05 12:15:13
|
Revision: 5253 http://sourceforge.net/p/modplug/code/5253 Author: manxorist Date: 2015-06-05 12:15:08 +0000 (Fri, 05 Jun 2015) Log Message: ----------- [Ref] Silence 2 rather bogus PathString warnings. Modified Paths: -------------- trunk/OpenMPT/mptrack/Moddoc.cpp trunk/OpenMPT/mptrack/Mptrack.cpp trunk/OpenMPT/mptrack/Mptrack.h Modified: trunk/OpenMPT/mptrack/Moddoc.cpp =================================================================== --- trunk/OpenMPT/mptrack/Moddoc.cpp 2015-06-04 18:21:22 UTC (rev 5252) +++ trunk/OpenMPT/mptrack/Moddoc.cpp 2015-06-05 12:15:08 UTC (rev 5253) @@ -1807,7 +1807,7 @@ if(strcmp(fileNameAdd, "")) { SanitizeFilename(fileNameAdd); - thisName += mpt::PathString::FromLocale(fileNameAdd); + thisName += mpt::PathString::FromUnicode(mpt::ToUnicode(mpt::CharsetLocale, fileNameAdd)); } thisName += fileExt; Modified: trunk/OpenMPT/mptrack/Mptrack.cpp =================================================================== --- trunk/OpenMPT/mptrack/Mptrack.cpp 2015-06-04 18:21:22 UTC (rev 5252) +++ trunk/OpenMPT/mptrack/Mptrack.cpp 2015-06-05 12:15:08 UTC (rev 5253) @@ -1951,9 +1951,15 @@ bool CTrackApp::OpenURL(const CString &url) //----------------------------------------- { - return OpenURL(mpt::PathString::FromCString(url)); + return OpenURL(mpt::ToUnicode(url)); } +bool CTrackApp::OpenURL(const mpt::ustring &url) +//---------------------------------------------- +{ + return OpenURL(mpt::PathString::FromUnicode(url)); +} + bool CTrackApp::OpenURL(const mpt::PathString &lpszURL) //----------------------------------------------------- { Modified: trunk/OpenMPT/mptrack/Mptrack.h =================================================================== --- trunk/OpenMPT/mptrack/Mptrack.h 2015-06-04 18:21:22 UTC (rev 5252) +++ trunk/OpenMPT/mptrack/Mptrack.h 2015-06-05 12:15:08 UTC (rev 5253) @@ -238,9 +238,10 @@ static BOOL SaveDefaultDLSBanks(); static BOOL RemoveDLSBank(UINT nBank); static BOOL AddDLSBank(const mpt::PathString &filename); - static bool OpenURL(const char *url); - static bool OpenURL(const std::string &url); + static bool OpenURL(const char *url); // UTF8 + static bool OpenURL(const std::string &url); // UTF8 static bool OpenURL(const CString &url); + static bool OpenURL(const mpt::ustring &url); static bool OpenURL(const mpt::PathString &lpszURL); static bool OpenFile(const mpt::PathString &file) { return OpenURL(file); }; static bool OpenDirectory(const mpt::PathString &directory) { return OpenURL(directory); }; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |