Fix "Common" to build with "Unicode" project setting.

This commit is contained in:
Jordan Woyak
2013-02-27 18:51:02 -06:00
parent ea75577278
commit 69f7671ee8
10 changed files with 63 additions and 59 deletions

View File

@ -102,6 +102,20 @@ std::string UriEncode(const std::string & sSrc);
std::string UTF16ToUTF8(const std::wstring& str);
std::wstring UTF8ToUTF16(const std::string& str);
#ifdef _UNICODE
inline std::string TStrToUTF8(const std::wstring& str)
{ return UTF16ToUTF8(str); }
inline std::wstring UTF8ToTStr(const std::string& str)
{ return UTF8ToUTF16(str); }
#else
inline std::string TStrToUTF8(const std::string& str)
{ return str; }
inline std::string UTF8ToTStr(const std::string& str)
{ return str; }
#endif
#endif
#endif // _STRINGUTIL_H_