mirror of
https://github.com/chibicitiberiu/rainmeter-studio.git
synced 2024-02-24 04:33:31 +00:00
The print() function in Lua scripts now outputs to Rainmeter log (an alternative to the TO.LuaLog() function).
This commit is contained in:
parent
251beb9e3a
commit
a69e2e91d2
@ -9,14 +9,12 @@ void push_wstring (lua_State* L, void* value, const char* type)
|
||||
lua_pushstring(L,str2.c_str());
|
||||
}
|
||||
|
||||
|
||||
void push_wchar(lua_State* L, void* value, const char* type)
|
||||
{
|
||||
std::string str2 = ConvertToAscii((WCHAR*)value);
|
||||
lua_pushstring(L,str2.c_str());
|
||||
}
|
||||
|
||||
|
||||
std::wstring to_wstring(lua_State* L, int arg, void* type)
|
||||
{
|
||||
// We have a static wstring here so we can keep a copy of the string
|
||||
|
@ -17,4 +17,3 @@ const wchar_t* to_wchar (lua_State* L, int arg, void* type);
|
||||
int is_wchar (lua_State* L, int lo, const char* type, int def, tolua_Error* err);
|
||||
|
||||
#endif
|
||||
|
||||
|
@ -195,5 +195,3 @@ bool LuaScript::FunctionExists(const char* p_strFuncName)
|
||||
|
||||
return bExists;
|
||||
}
|
||||
|
||||
|
||||
|
@ -114,6 +114,7 @@ static const luaL_reg rainmeter_ext_funcs[] =
|
||||
|
||||
TOLUA_API int luaopen_rainmeter_ext (lua_State* L)
|
||||
{
|
||||
lua_register(L, "print", staticLuaLog);
|
||||
luaL_register(L,"TO", rainmeter_ext_funcs);
|
||||
return 1;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user