From: John L. <jr...@us...> - 2006-02-02 17:05:50
|
Update of /cvsroot/wxlua/wxLua/modules/wxlua/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28688/wxLua/modules/wxlua/src Modified Files: wxlbind.cpp Log Message: add the overrides to the wxstc module Index: wxlbind.cpp =================================================================== RCS file: /cvsroot/wxlua/wxLua/modules/wxlua/src/wxlbind.cpp,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** wxlbind.cpp 2 Feb 2006 15:49:25 -0000 1.14 --- wxlbind.cpp 2 Feb 2006 17:05:42 -0000 1.15 *************** *** 248,258 **** // create a global for the namespace if it doesn't already exist lua_getglobal(L, wx2lua(nameSpace)); if (!lua_istable(L, -1)) { lua_pushstring(L, wx2lua(nameSpace)); lua_pushvalue(L, luaTable); } - lua_rawset(L, LUA_GLOBALSINDEX); lua_pop(L, 1); } --- 248,261 ---- // create a global for the namespace if it doesn't already exist lua_getglobal(L, wx2lua(nameSpace)); + if (!lua_istable(L, -1)) { + lua_pop(L, 1); // pop the nil value + lua_pushstring(L, wx2lua(nameSpace)); lua_pushvalue(L, luaTable); + lua_rawset(L, LUA_GLOBALSINDEX); } lua_pop(L, 1); } *************** *** 279,284 **** if (!lua_istable(L, -1)) { ! // pop the nil value ! lua_pop(L, 1); // create references table in registry --- 282,286 ---- if (!lua_istable(L, -1)) { ! lua_pop(L, 1); // pop the nil value // create references table in registry *************** *** 326,330 **** OnRegister(wxlState, registerTypes, tableOffset); ! m_typesRegistered = true; return tableOffset; --- 328,332 ---- OnRegister(wxlState, registerTypes, tableOffset); ! m_typesRegistered = true; return tableOffset; |