From e92caa97329016d012b46b9d37e1b2c3b613a8f2 Mon Sep 17 00:00:00 2001 From: chai Date: Sat, 10 Nov 2018 20:13:55 +0800 Subject: =?UTF-8?q?*=E4=BF=AE=E6=94=B9=E4=BB=A3=E7=A0=81=E7=BB=93=E6=9E=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/lua/modules/graphics/je_lua_bitmap.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/lua/modules/graphics/je_lua_bitmap.cpp') diff --git a/src/lua/modules/graphics/je_lua_bitmap.cpp b/src/lua/modules/graphics/je_lua_bitmap.cpp index a8d5bc0..8d4897b 100644 --- a/src/lua/modules/graphics/je_lua_bitmap.cpp +++ b/src/lua/modules/graphics/je_lua_bitmap.cpp @@ -10,12 +10,12 @@ namespace JinEngine namespace Lua { - typedef Ref& BitmapRef; + typedef Shared& BitmapRef; LUA_IMPLEMENT inline BitmapRef checkBitmap(lua_State* L) { Proxy* proxy = (Proxy*)luax_checktype(L, 1, JIN_GRAPHICS_BITMAP); - return proxy->getRef(); + return proxy->getShared(); } LUA_IMPLEMENT int l_gc(lua_State* L) @@ -88,7 +88,7 @@ namespace JinEngine Bitmap* bitmap = ref.getObject(); Bitmap* b = Bitmap::clone(bitmap); Proxy* proxy = (Proxy*)luax_newinstance(L, JIN_GRAPHICS_BITMAP, sizeof(Proxy)); - proxy->bind(new Ref(b, JIN_GRAPHICS_BITMAP)); + proxy->bind(new Shared(b, JIN_GRAPHICS_BITMAP)); return 1; } -- cgit v1.1-26-g67d0