use wstrings uncoditionally where needed

This commit is contained in:
Andrzej Rybczak
2012-09-08 17:50:01 +02:00
parent cf06d9fa8d
commit d5e2d315fd
46 changed files with 196 additions and 221 deletions

View File

@@ -133,9 +133,9 @@ void Help::SwitchTo()
DrawHeader();
}
std::basic_string<my_char_t> Help::Title()
std::wstring Help::Title()
{
return U("Help");
return L"Help";
}
std::string Help::DisplayKeys(const ActionType at)
@@ -156,25 +156,25 @@ std::string Help::DisplayKeys(const ActionType at)
void Help::Section(const char *type, const char *title)
{
*w << U("\n ") << NC::fmtBold << TO_WSTRING(type) << U(" - ");
*w << TO_WSTRING(title) << NC::fmtBoldEnd << '\n' << '\n';
*w << L"\n " << NC::fmtBold << ToWString(type) << L" - ";
*w << ToWString(title) << NC::fmtBoldEnd << L"\n\n";
}
void Help::KeyDesc(const ActionType at, const char *desc)
{
*w << U(" ") << DisplayKeys(at) << U(" : ") << TO_WSTRING(desc) << '\n';
*w << L" " << DisplayKeys(at) << L" : " << ToWString(desc) << '\n';
}
void Help::MouseDesc(std::string action, const char *desc, bool indent)
{
action.resize(31 - (indent ? 2 : 0), ' ');
*w << U(" ") << (indent ? U(" ") : U("")) << TO_WSTRING(action);
*w << U(": ") << TO_WSTRING(desc) << '\n';
*w << L" " << (indent ? L" " : L"") << ToWString(action);
*w << L": " << ToWString(desc) << '\n';
}
void Help::MouseColumn(const char *column)
{
*w << NC::fmtBold << U(" ") << TO_WSTRING(column) << U(" column:\n") << NC::fmtBoldEnd;
*w << NC::fmtBold << L" " << ToWString(column) << L" column:\n" << NC::fmtBoldEnd;
}
void Help::GetKeybindings()