Fix umlauts/special character issue in lua gettext
parent
deaa8dc287
commit
78ea818aaf
|
@ -979,9 +979,8 @@ int ModApiMainMenu::l_download_file(lua_State *L)
|
||||||
/******************************************************************************/
|
/******************************************************************************/
|
||||||
int ModApiMainMenu::l_gettext(lua_State *L)
|
int ModApiMainMenu::l_gettext(lua_State *L)
|
||||||
{
|
{
|
||||||
const char* str = luaL_checkstring(L, 1);
|
std::wstring wtext = wstrgettext((std::string) luaL_checkstring(L, 1));
|
||||||
str = gettext(str);
|
lua_pushstring(L, wide_to_narrow(wtext).c_str());
|
||||||
lua_pushstring(L, str);
|
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue