src: switch to wstring for printing messages

This commit is contained in:
mlangkabel
2018-02-06 10:03:46 +01:00
parent 1d7fc6e9d4
commit 9da3ac3d3c
36 changed files with 127 additions and 89 deletions
+5 -4
View File
@@ -5,6 +5,7 @@
#include <sstream>
#include "utility/types.h"
#include "utility/utilityString.h"
class MessageBase
{
@@ -92,12 +93,12 @@ public:
return m_keepContent;
}
virtual void print(std::ostream& os) const = 0;
virtual void print(std::wostream& os) const = 0;
std::string str() const
std::wstring str() const
{
std::stringstream ss;
ss << getType() << " ";
std::wstringstream ss;
ss << utility::decodeFromUtf8(getType()) << L" ";
print(ss);
return ss.str();
}