summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWilliam Wilgus <me.theuser@yahoo.com>2018-10-25 07:10:46 -0400
committerWilliam Wilgus <me.theuser@yahoo.com>2018-10-25 07:10:46 -0400
commit5449500a67e39a5c89f233b075589fd57111e177 (patch)
tree789f7c5e9108a071cff4ac3100cdc9fe1c0be843
parent55533c4d36748d30a1ab5d49c35abae19077c7fe (diff)
downloadrockbox-5449500a67e39a5c89f233b075589fd57111e177.tar.gz
rockbox-5449500a67e39a5c89f233b075589fd57111e177.zip
Lua Rlimage metatable
Put rliimage functions into the rb.image metatable instead of the rb. table Change-Id: Iecdc564c2ea9739656e2025b51bb5d5c62e3dbc1
-rw-r--r--apps/plugins/lua/rocklib_img.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/apps/plugins/lua/rocklib_img.c b/apps/plugins/lua/rocklib_img.c
index 909f1b61b9..45012ece20 100644
--- a/apps/plugins/lua/rocklib_img.c
+++ b/apps/plugins/lua/rocklib_img.c
@@ -1424,9 +1424,10 @@ LUALIB_API int luaopen_rock_img(lua_State *L)
1424 1424
1425 lua_pushvalue(L, -1); /* pushes the metatable */ 1425 lua_pushvalue(L, -1); /* pushes the metatable */
1426 lua_setfield(L, -2, "__index"); /* metatable.__index = metatable */ 1426 lua_setfield(L, -2, "__index"); /* metatable.__index = metatable */
1427 luaL_register(L, NULL, rli_lib); /*add rli_lib to the image metatable*/
1427 1428
1428 luaL_register(L, LUA_ROCKLIBNAME, rocklib_img); 1429 luaL_register(L, LUA_ROCKLIBNAME, rocklib_img);
1429 luaL_register(L, NULL, rli_lib);
1430 1430
1431 return 1; 1431 return 1;
1432} 1432}
1433