iup-stack/iup/srclua5/ctrl/tuioclient.lua

41 lines
810 B
Lua
Raw Permalink Normal View History

2023-02-20 16:44:45 +00:00
------------------------------------------------------------------------------
-- TuioClient class
------------------------------------------------------------------------------
local ctrl = {
nick = "tuioclient",
parent = iup.WIDGET,
creation = "N", -- optional integer
funcname = "TuioClient",
subdir = "ctrl",
callback = {
},
include = "iuptuio.h",
extracode = [[
int iuptuiolua_open(lua_State* L)
{
if (iuplua_opencall_internal(L))
IupTuioOpen();
iuplua_get_env(L);
iuptuioclientlua_open(L);
return 0;
}
/* obligatory to use require"iupluatuio" */
int luaopen_iupluatuio(lua_State* L)
{
return iuptuiolua_open(L);
}
]]
}
function ctrl.createElement(class, param)
return iup.TuioClient(param[1])
end
iup.RegisterWidget(ctrl)
iup.SetClass(ctrl, "iupWidget")