From 5c9af043503f92852a1a765b6ecfbc1aea24d2e9 Mon Sep 17 00:00:00 2001 From: chai Date: Tue, 14 Aug 2018 14:56:47 +0800 Subject: *update --- src/lua/graphics/luaopen_Canvas.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src/lua/graphics/luaopen_Canvas.cpp') diff --git a/src/lua/graphics/luaopen_Canvas.cpp b/src/lua/graphics/luaopen_Canvas.cpp index 808a977..d08b181 100644 --- a/src/lua/graphics/luaopen_Canvas.cpp +++ b/src/lua/graphics/luaopen_Canvas.cpp @@ -1,13 +1,13 @@ #include "lua/luax.h" #include "lua/luaopen_types.h" -#include "libjin/jin.h" +#include "Canvas.h" namespace jin { namespace lua { - using namespace jin::graphics; + using namespace lua::graphics; static inline Canvas* checkCanvas(lua_State* L) { @@ -51,8 +51,7 @@ namespace lua static int l_gc(lua_State* L) { Proxy* proxy = (Proxy*)luax_checktype(L, 1, JIN_GRAPHICS_CANVAS); - Canvas* canvas = (Canvas*)proxy->object; - delete canvas; + proxy->release(); return 0; } -- cgit v1.1-26-g67d0