mirror of
https://github.com/1dot13/source.git
synced 2026-07-22 13:40:22 +02:00
- Merged 2 fixes from MP Branch
o VFS: don't convert empty strings o Updated _PolishText.cpp git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@3109 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -3298,7 +3298,7 @@ STR16 AimPopUpText[] =
|
||||
|
||||
//If you try to hire more mercs than game can support
|
||||
|
||||
L"Masz ju¿ pe³ny zespó³ 18 najemników.",
|
||||
L"You have a full team of mercs already.",
|
||||
|
||||
L"Nagrana wiadomoϾ",
|
||||
L"WiadomoϾ zapisana",
|
||||
|
||||
@@ -203,6 +203,10 @@ std::string utf8string::as_utf8(utf8string const& str)
|
||||
}
|
||||
std::string utf8string::as_utf8(std::wstring const& str)
|
||||
{
|
||||
if(str.length() == 0)
|
||||
{
|
||||
return "";
|
||||
}
|
||||
#if 0
|
||||
std::string s;
|
||||
utf8::utf16to8(str.begin(), str.end(), std::back_inserter(s));
|
||||
@@ -224,6 +228,10 @@ std::string utf8string::as_utf8(const wchar_t* str, unsigned int strlength)
|
||||
{
|
||||
len = wcslen(str);
|
||||
}
|
||||
if(len == 0)
|
||||
{
|
||||
return "";
|
||||
}
|
||||
utf8::utf16to8(str,str+len,std::back_inserter(s));
|
||||
return s;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user