mirror of
https://github.com/narzoul/DDrawCompat
synced 2024-12-30 08:55:36 +01:00
Added logging of wide-character string parameters
This commit is contained in:
parent
a573c1344c
commit
14d28fe7ac
@ -1,5 +1,6 @@
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
|
||||
#include <atlstr.h>
|
||||
#include <Windows.h>
|
||||
|
||||
#include "DDrawLog.h"
|
||||
@ -15,6 +16,12 @@ namespace
|
||||
}
|
||||
}
|
||||
|
||||
std::ostream& operator<<(std::ostream& os, const WCHAR* wstr)
|
||||
{
|
||||
CStringA str(wstr);
|
||||
return os << '"' << static_cast<const char*>(str) << '"';
|
||||
}
|
||||
|
||||
std::ostream& operator<<(std::ostream& os, const RECT& rect)
|
||||
{
|
||||
return os << "R(" << rect.left << ',' << rect.top << ',' << rect.right << ',' << rect.bottom << ')';
|
||||
|
@ -14,6 +14,7 @@
|
||||
isAlreadyLogged##__LINE__ = true; \
|
||||
}
|
||||
|
||||
std::ostream& operator<<(std::ostream& os, const WCHAR* wstr);
|
||||
std::ostream& operator<<(std::ostream& os, const RECT& rect);
|
||||
std::ostream& operator<<(std::ostream& os, const DDSCAPS& caps);
|
||||
std::ostream& operator<<(std::ostream& os, const DDSCAPS2& caps);
|
||||
|
Loading…
x
Reference in New Issue
Block a user