summaryrefslogtreecommitdiff
path: root/client/widgets/checkbox.cc
diff options
context:
space:
mode:
Diffstat (limited to 'client/widgets/checkbox.cc')
-rw-r--r--client/widgets/checkbox.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/client/widgets/checkbox.cc b/client/widgets/checkbox.cc
index 9083990..7d81b1a 100644
--- a/client/widgets/checkbox.cc
+++ b/client/widgets/checkbox.cc
@@ -132,7 +132,7 @@ int chk_checked(lua_State *L)
{
wdg_userdata *wdgu;
- wdgu = (wdg_userdata *)luaL_isudata(L, 1, "CheckBox");
+ wdgu = (wdg_userdata *)lua_touserdata(L, 1);
luaL_argcheck(L, wdgu, 1, "checkbox expected");
CheckBox *chk = (CheckBox*)wdgu->widget;
@@ -145,7 +145,7 @@ int chk_set_checked(lua_State *L)
{
wdg_userdata *wdgu;
- wdgu = (wdg_userdata *)luaL_isudata(L, 1, "CheckBox");
+ wdgu = (wdg_userdata *)lua_touserdata(L, 1);
luaL_argcheck(L, wdgu, 1, "checkbox expected");
bool val = luaL_checkbool(L, 2);