summaryrefslogtreecommitdiffstats
path: root/src/app/system_windows.h
diff options
context:
space:
mode:
authorPiotr Dziwinski <piotrdz@gmail.com>2012-09-19 22:53:06 +0200
committerPiotr Dziwinski <piotrdz@gmail.com>2012-09-19 22:53:06 +0200
commit7479f486b671acb2a6aea2c84a56b383aaba00ca (patch)
tree4043545a14234dfaa2d7d08d59c7ee9ee97f0de9 /src/app/system_windows.h
parent901f10b2bac18a2063cd21798f22b3917e8519b5 (diff)
parent57d33d79ea570773d84ad81d4a61f50e079979ef (diff)
downloadcolobot-7479f486b671acb2a6aea2c84a56b383aaba00ca.tar.gz
colobot-7479f486b671acb2a6aea2c84a56b383aaba00ca.tar.bz2
colobot-7479f486b671acb2a6aea2c84a56b383aaba00ca.zip
Forgotten fix in dev-graphics
Diffstat (limited to 'src/app/system_windows.h')
-rw-r--r--src/app/system_windows.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/app/system_windows.h b/src/app/system_windows.h
index 72d9f88..c9743e6 100644
--- a/src/app/system_windows.h
+++ b/src/app/system_windows.h
@@ -48,18 +48,18 @@ struct SystemTimeStamp
// Convert a wide Unicode string to an UTF8 string
std::string UTF8_Encode_Windows(const std::wstring &wstr)
{
- int size_needed = WideCharToMultiByte(CP_UTF8, 0, &wstr[0], (int)wstr.size(), NULL, 0, NULL, NULL);
+ int size_needed = WideCharToMultiByte(CP_UTF8, 0, &wstr[0], static_cast<int>(wstr.size()), NULL, 0, NULL, NULL);
std::string strTo(size_needed, 0);
- WideCharToMultiByte(CP_UTF8, 0, &wstr[0], (int)wstr.size(), &strTo[0], size_needed, NULL, NULL);
+ WideCharToMultiByte(CP_UTF8, 0, &wstr[0], static_cast<int>(wstr.size()), &strTo[0], size_needed, NULL, NULL);
return strTo;
}
// Convert an UTF8 string to a wide Unicode String
std::wstring UTF8_Decode_Windows(const std::string &str)
{
- int size_needed = MultiByteToWideChar(CP_UTF8, 0, &str[0], (int)str.size(), NULL, 0);
+ int size_needed = MultiByteToWideChar(CP_UTF8, 0, &str[0], static_cast<int>(str.size()), NULL, 0);
std::wstring wstrTo(size_needed, 0);
- MultiByteToWideChar(CP_UTF8, 0, &str[0], (int)str.size(), &wstrTo[0], size_needed);
+ MultiByteToWideChar(CP_UTF8, 0, &str[0], static_cast<int>(str.size()), &wstrTo[0], size_needed);
return wstrTo;
}