Update of /cvsroot/wxlua/wxLua/bindings/wxlua
In directory sc8-pr-cvs9.sourceforge.net:/tmp/cvs-serv13186/wxLua/bindings/wxlua
Modified Files:
override.hpp wxlua.i
Log Message:
Streamlined wxLuaBinding::RegisterBinding(...) and remove the bool
"registerClasses" since it didn't do anything useful anyway.
If there needs to be a way to reregister the wxLua functions it should
to be implemented from the ground up.
Renamed the functions wxlua_txxx to wxluaT_xxx to make it easier to
search for their usage. The functions in the wxLuaState used to be
called just "txxx" and are now called wxluaT_Xxx where the first
letter or each word is capitalized (camel-case); again for searching.
* This is the beginning of the separation between the "wxLuaReferences"
being used for both the "tags" for identifying classes and for just
having references to objects so Lua won't GC them.
Index: wxlua.i
===================================================================
RCS file: /cvsroot/wxlua/wxLua/bindings/wxlua/wxlua.i,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** wxlua.i 15 Oct 2007 21:27:42 -0000 1.8
--- wxlua.i 17 Nov 2007 00:14:55 -0000 1.9
***************
*** 102,106 ****
// Given any type of object, returns four values:
// wxlua name of the type - wxLuaState::GetLuaTagName(wxlua_type)
! // wxlua number of the type - wxlua_getwxluatype(lua_type(L, stack_idx)) or wxlua_ttag
// lua name of the type - lua_typename(L, lua_type(L, stack_idx))
// lua number of the type - lua_type(L, stack_idx)
--- 102,106 ----
// Given any type of object, returns four values:
// wxlua name of the type - wxLuaState::GetLuaTagName(wxlua_type)
! // wxlua number of the type - wxlua_getwxluatype(lua_type(L, stack_idx)) or wxluaT_tag
// lua name of the type - lua_typename(L, lua_type(L, stack_idx))
// lua number of the type - lua_type(L, stack_idx)
Index: override.hpp
===================================================================
RCS file: /cvsroot/wxlua/wxLua/bindings/wxlua/override.hpp,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** override.hpp 19 Jul 2007 03:09:45 -0000 1.7
--- override.hpp 17 Nov 2007 00:14:55 -0000 1.8
***************
*** 133,137 ****
// this may a wxLua data
if (ltype == LUA_TUSERDATA)
! wxluaarg_tag = wxlua_ttag(L, 1);
// I guess it wasn't or isn't a userdata
--- 133,137 ----
// this may a wxLua data
if (ltype == LUA_TUSERDATA)
! wxluaarg_tag = wxluaT_tag(L, 1);
// I guess it wasn't or isn't a userdata
***************
*** 735,741 ****
lua_pushstring(L, "object");
if (wxlObject->objPtr != 0)
! wxlState.tpushusertag(wxlObject->objPtr, *wxlObject->class_tag, false);
else
! wxlState.tpushusertag(*wxlObject->pObjPtr, *wxlObject->class_tag, false);
lua_rawset(L, -3);
--- 735,741 ----
lua_pushstring(L, "object");
if (wxlObject->objPtr != 0)
! wxlState.wxluaT_PushUserTag(wxlObject->objPtr, *wxlObject->class_tag, false);
else
! wxlState.wxluaT_PushUserTag(*wxlObject->pObjPtr, *wxlObject->class_tag, false);
lua_rawset(L, -3);
|