From 2f27af125ec76c90571c4c07822157d646bb0ffc Mon Sep 17 00:00:00 2001 From: Ulukyn Date: Mon, 13 Jan 2020 12:28:21 +0100 Subject: [PATCH] Added: encodeURLParam --- code/ryzom/client/src/interface_v3/lua_ihm_ryzom.cpp | 8 ++++++++ code/ryzom/client/src/interface_v3/lua_ihm_ryzom.h | 1 + 2 files changed, 9 insertions(+) diff --git a/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.cpp b/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.cpp index 547388698..e011f6e15 100644 --- a/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.cpp +++ b/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.cpp @@ -591,6 +591,7 @@ void CLuaIHMRyzom::RegisterRyzomFunctions(NLGUI::CLuaState &ls) LUABIND_FUNC(updateTooltipCoords), LUABIND_FUNC(isCtrlKeyDown), LUABIND_FUNC(encodeURLUnicodeParam), + LUABIND_FUNC(encodeURLParam), LUABIND_FUNC(getPlayerLevel), LUABIND_FUNC(getPlayerVpa), LUABIND_FUNC(getPlayerVpb), @@ -3772,6 +3773,13 @@ std::string CLuaIHMRyzom::encodeURLUnicodeParam(const ucstring &text) return convertToHTML(text.toUtf8()); } +// *************************************************************************** +std::string CLuaIHMRyzom::encodeURLParam(const string &text) +{ + //H_AUTO(Lua_CLuaIHM_encodeURLUnicodeParam) + return convertToHTML(text); +} + // *************************************************************************** sint32 CLuaIHMRyzom::getPlayerLevel() { diff --git a/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.h b/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.h index 5103d2fcf..3a9eed78a 100644 --- a/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.h +++ b/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.h @@ -259,6 +259,7 @@ private: // because it would be too easy to write a key recorder ...) static bool isCtrlKeyDown(); static std::string encodeURLUnicodeParam(const ucstring &text); + static std::string encodeURLParam(const std::string &text); static sint32 getPlayerLevel(); // get max level among player skills (magi, combat, crafting ,foraging) static std::string getPlayerVpaHex();