forked from cafeberry/cafeberry
feat: durango ui parity & setting name
This commit is contained in:
@@ -126,7 +126,7 @@ void CConsoleMinecraftApp::FatalLoadError()
|
||||
);
|
||||
|
||||
if (result == IDOK) {
|
||||
ExitGame();
|
||||
PostQuitMessage(1); //str1k3r - since this is a fatal load error, exit with a nonzero exitcode
|
||||
}
|
||||
}
|
||||
|
||||
@@ -233,3 +233,16 @@ std::wstring CConsoleMinecraftApp::UTF8ToWide(const char* utf8)
|
||||
wstr.resize(size - 1);
|
||||
return wstr;
|
||||
}
|
||||
|
||||
void CConsoleMinecraftApp::CopyWideArgToAnsi(LPCWSTR source, char* dest, size_t destSize)
|
||||
{
|
||||
if (destSize == 0)
|
||||
return;
|
||||
|
||||
dest[0] = 0;
|
||||
if (source == nullptr)
|
||||
return;
|
||||
|
||||
WideCharToMultiByte(CP_ACP, 0, source, -1, dest, static_cast<int>(destSize), nullptr, nullptr);
|
||||
dest[destSize - 1] = 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user