From: John L. <jr...@us...> - 2008-01-04 00:21:19
|
Update of /cvsroot/wxlua/wxLua/modules/wxlua/include In directory sc8-pr-cvs9.sourceforge.net:/tmp/cvs-serv6007/wxLua/modules/wxlua/include Modified Files: wxlbind.h wxlcallb.h wxldefs.h wxlstate.h wxlua.h Log Message: Fix typos in comments Only need wxWindow = wxLuaWinDestroyCallback in the wxlua_lreg_windestroycallbacks_key table Index: wxldefs.h =================================================================== RCS file: /cvsroot/wxlua/wxLua/modules/wxlua/include/wxldefs.h,v retrieving revision 1.40 retrieving revision 1.41 diff -C2 -d -r1.40 -r1.41 *** wxldefs.h 22 Dec 2007 06:07:15 -0000 1.40 --- wxldefs.h 4 Jan 2008 00:21:08 -0000 1.41 *************** *** 3,9 **** // Purpose: wxLua common defines // Author: John Labenski - // Modified by: // Created: 5/28/2005 - // RCS-ID: // Copyright: (c) John Labenski // Licence: wxWidgets licence --- 3,7 ---- Index: wxlcallb.h =================================================================== RCS file: /cvsroot/wxlua/wxLua/modules/wxlua/include/wxlcallb.h,v retrieving revision 1.27 retrieving revision 1.28 diff -C2 -d -r1.27 -r1.28 *** wxlcallb.h 3 Jan 2008 00:05:58 -0000 1.27 --- wxlcallb.h 4 Jan 2008 00:21:08 -0000 1.28 *************** *** 19,23 **** // The wxLuaEventCallback is created with the wxLuaState, the stack index of a // Lua function to call when a wxEvent is received, the window id ranges, and ! // the wxEventType used with wxEvtHandler::Connect() with this as the // callback user data for event. // --- 19,23 ---- // The wxLuaEventCallback is created with the wxLuaState, the stack index of a // Lua function to call when a wxEvent is received, the window id ranges, and ! // the wxEventType used with wxEvtHandler::Connect() with "this" as the // callback user data for event. // *************** *** 41,45 **** virtual ~wxLuaEventCallback(); ! // Verifies the inputs and calls evtHandler->Connect() with this as // the callback userdata. // lua_func_stack_idx is the Lua stack index of a function to call with --- 41,45 ---- virtual ~wxLuaEventCallback(); ! // Verifies the inputs and calls evtHandler->Connect() with "this" as // the callback userdata. // lua_func_stack_idx is the Lua stack index of a function to call with *************** *** 64,74 **** const wxLuaBindEvent* GetwxLuaBindEvent() const { return m_wxlBindEvent; } ! // Get a human readable string // "wxEVT_XXX(evt#) -> wxLuaEventCallback(&callback, ids %d %d)|wxEvtHandler(&evthandler) -> wxEvtHandlerClassName" wxString GetInfo() const; // Get a human readable string // Central event handler that calls OnEvent() for the actual ! // wxLuaEventCallback callback userdata. This function is treated like a ! // static function that all handlers of this class will call. void OnAllEvents(wxEvent& event); --- 64,75 ---- const wxLuaBindEvent* GetwxLuaBindEvent() const { return m_wxlBindEvent; } ! // Get a human readable string about this callback. // "wxEVT_XXX(evt#) -> wxLuaEventCallback(&callback, ids %d %d)|wxEvtHandler(&evthandler) -> wxEvtHandlerClassName" wxString GetInfo() const; // Get a human readable string // Central event handler that calls OnEvent() for the actual ! // wxLuaEventCallback callback userdata. ! // This function is treated like a static function that all handlers of ! // this class will call. void OnAllEvents(wxEvent& event); *************** *** 78,83 **** protected: ! int m_luafunc_ref; // ref to the Lua routine to call in the wxlua_lreg_refs_key registry table ! wxLuaState m_wxlState; // store it since we're added to a list of its callbacks. wxEvtHandler* m_evtHandler; wxWindowID m_id; --- 79,84 ---- protected: ! int m_luafunc_ref; // ref of the Lua routine to call in the wxlua_lreg_refs_key registry table ! wxLuaState m_wxlState; // stored to verify that that lua_State is still active wxEvtHandler* m_evtHandler; wxWindowID m_id; *************** *** 119,127 **** // Central event handler that calls OnDestroy() for the actual ! // wxLuaWinDestroyCallback callback user data. This function is treated like a ! // static function that all handlers of this class will call. void OnAllDestroyEvents(wxWindowDestroyEvent& event); ! // Handle the event by clearing the metatable for the window virtual void OnDestroy(wxWindowDestroyEvent& event); --- 120,129 ---- // Central event handler that calls OnDestroy() for the actual ! // wxLuaWinDestroyCallback callback user data. ! // This function is treated like a static function that all handlers of ! // this class will call. void OnAllDestroyEvents(wxWindowDestroyEvent& event); ! // Handle the event by clearing the metatable for the window. virtual void OnDestroy(wxWindowDestroyEvent& event); Index: wxlua.h =================================================================== RCS file: /cvsroot/wxlua/wxLua/modules/wxlua/include/wxlua.h,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** wxlua.h 23 Feb 2006 05:51:46 -0000 1.6 --- wxlua.h 4 Jan 2008 00:21:08 -0000 1.7 *************** *** 1,3 **** --- 1,4 ---- ///////////////////////////////////////////////////////////////////////////// + // Name: wxlua.h // Purpose: Single header to include for wxLua // Author: J Winwood Index: wxlbind.h =================================================================== RCS file: /cvsroot/wxlua/wxLua/modules/wxlua/include/wxlbind.h,v retrieving revision 1.76 retrieving revision 1.77 diff -C2 -d -r1.76 -r1.77 *** wxlbind.h 3 Jan 2008 00:05:58 -0000 1.76 --- wxlbind.h 4 Jan 2008 00:21:08 -0000 1.77 *************** *** 1,7 **** ///////////////////////////////////////////////////////////////////////////// // Purpose: wxLuaBinding // Author: Ray Gilbert, John Labenski, J Winwood // Created: 14/11/2001 ! // Copyright: // Licence: wxWidgets licence ///////////////////////////////////////////////////////////////////////////// --- 1,8 ---- ///////////////////////////////////////////////////////////////////////////// + // Name: wxlbind.h // Purpose: wxLuaBinding // Author: Ray Gilbert, John Labenski, J Winwood // Created: 14/11/2001 ! // Copyright: Ray Gilbert // Licence: wxWidgets licence ///////////////////////////////////////////////////////////////////////////// Index: wxlstate.h =================================================================== RCS file: /cvsroot/wxlua/wxLua/modules/wxlua/include/wxlstate.h,v retrieving revision 1.112 retrieving revision 1.113 diff -C2 -d -r1.112 -r1.113 *** wxlstate.h 22 Dec 2007 06:07:15 -0000 1.112 --- wxlstate.h 4 Jan 2008 00:21:08 -0000 1.113 *************** *** 1,4 **** ///////////////////////////////////////////////////////////////////////////// ! // Purpose: wxWidgets interface to Lua // Author: Ray Gilbert, John Labenski, J Winwood // Created: 14/11/2001 --- 1,5 ---- ///////////////////////////////////////////////////////////////////////////// ! // Name: wxlstate.h ! // Purpose: wxLuaState - a wxWidgets interface to Lua // Author: Ray Gilbert, John Labenski, J Winwood // Created: 14/11/2001 *************** *** 70,74 **** // ---------------------------------------------------------------------------- ! // Special keys used by wxLua // // Note: We do not push a human readable string for these because Lua always --- 71,75 ---- // ---------------------------------------------------------------------------- ! // Special keys used by wxLua in the LUA_REGISTRYINDEX table. // // Note: We do not push a human readable string for these because Lua always *************** *** 77,84 **** // ---------------------------------------------------------------------------- ! // Light userdata used as keys in the Lua LUA_REGISTRYINDEX table for wxLua items. // Note that even though these keys have values, they're not used, just the memory address. ! // The key in the LUA_REGISTRYINDEX table that is a table indexed // on the wxLua types where each item is a userdata metatable for a C++ class. // Note: The wxLua types WXLUA_TXXX that correspond to the Lua LUA_TXXX types --- 78,85 ---- // ---------------------------------------------------------------------------- ! // Light userdata used as keys in the Lua LUA_REGISTRYINDEX table for wxLua. // Note that even though these keys have values, they're not used, just the memory address. ! // The key in the LUA_REGISTRYINDEX table that is a numerically keyed table indexed // on the wxLua types where each item is a userdata metatable for a C++ class. // Note: The wxLua types WXLUA_TXXX that correspond to the Lua LUA_TXXX types *************** *** 93,106 **** extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_refs_key; // The key in the LUA_REGISTRYINDEX table that is a numerically keyed table ! // with references to objects the wxLuaDebugData wants to keep a handle to. It ! // stores their value for faster lookup. It is used only for the wxLuaDebugData. // LUA_REGISTRYINDEX[&wxlua_lreg_debug_refs_key][ref number] = Lua object extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_debug_refs_key; ! // The key that in the LUA_REGISTRYINDEX table that is a table of ! // C++ classname keys and lightuserdata pointers to the associated wxLuaBindClass. // LUA_REGISTRYINDEX[&wxlua_lreg_debug_refs_key][wxLuaBindClass.name] = lightuserdata(&wxLuaBindClass) extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_classes_key; // The key in the LUA_REGISTRYINDEX table that is a table ! // of Lua functions assigned to wxLua userdata programatically in Lua. // LUA_REGISTRYINDEX[&wxlua_lreg_derivedmethods_key][lightuserdata(obj_ptr)] = // {["derived func/value name"] = wxLuaObject(Lua function/value), ...} --- 94,107 ---- extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_refs_key; // The key in the LUA_REGISTRYINDEX table that is a numerically keyed table ! // with references to objects the wxLuaDebugData wants to keep a handle to and ! // stores their value for lookup. It is used only for the wxLuaDebugData. // LUA_REGISTRYINDEX[&wxlua_lreg_debug_refs_key][ref number] = Lua object extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_debug_refs_key; ! // The key that in the LUA_REGISTRYINDEX table that is a lookup table of string ! // C++ classname keys and lightuserdata pointers to the associated wxLuaBindClass struct. // LUA_REGISTRYINDEX[&wxlua_lreg_debug_refs_key][wxLuaBindClass.name] = lightuserdata(&wxLuaBindClass) extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_classes_key; // The key in the LUA_REGISTRYINDEX table that is a table ! // of Lua objects/functions assigned to wxLua userdata programatically in Lua. // LUA_REGISTRYINDEX[&wxlua_lreg_derivedmethods_key][lightuserdata(obj_ptr)] = // {["derived func/value name"] = wxLuaObject(Lua function/value), ...} *************** *** 110,114 **** // LUA_REGISTRYINDEX[&wxlua_lreg_wxluastate_key] = lightuserdata(&wxLuaState) extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_wxluastate_key; ! // The key in the LUA_REGISTRYINDEX table that is table of all // objects that we've pushed into Lua using wxluaT_pushuserdatatype(). // Note: A single object like a wxWindow may be pushed with multiple wxLua types. --- 111,115 ---- // LUA_REGISTRYINDEX[&wxlua_lreg_wxluastate_key] = lightuserdata(&wxLuaState) extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_wxluastate_key; ! // The key in the LUA_REGISTRYINDEX table that is a table of all // objects that we've pushed into Lua using wxluaT_pushuserdatatype(). // Note: A single object like a wxWindow may be pushed with multiple wxLua types. *************** *** 117,141 **** // { wxLua type1 = weak fulluserdata, wxLua type2 = weak fulluserdata... } extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_weakobjects_key; ! // The key in the LUA_REGISTRYINDEX table that is table of all ! // objects tracked using wxluaO_addgcobject() to delete them when done. // Note that non wxObject classes use wxLUA_DECLARE_ENCAPSULATION so // the key is the object pointer and the value is the wxObject encapsulation. ! // Both the key and the value are the same if not encapsulated . // LUA_REGISTRYINDEX[&wxlua_lreg_gcobjects_key][lightuserdata(obj_ptr)] = // lightuserdata(wxObject derived class) extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_gcobjects_key; ! // The key in the LUA_REGISTRYINDEX table that is table of all // wxLuaEventCallbacks that we've created. // LUA_REGISTRYINDEX[&wxlua_lreg_evtcallbacks_key][lightuserdata(&wxLuaEventCallback)] = // lightuserdata(&wxEvtHandler) extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_evtcallbacks_key; ! // The key in the LUA_REGISTRYINDEX table that is table of all ! // wxLuaWinDestroyCallbacks that we've created. ! // Two key/value pairs are created for fast lookup. ! // LUA_REGISTRYINDEX[&wxlua_lreg_windestroycallbacks_key][lightuserdata(&wxLuaWinDestroyCallback)] = 1 // LUA_REGISTRYINDEX[&wxlua_lreg_windestroycallbacks_key][lightuserdata(&wxWindow)] = // lightuserdata(wxLuaWinDestroyCallback) extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_windestroycallbacks_key; ! // The key in the LUA_REGISTRYINDEX table that is table of all // top level wxWindows that we've created and need to destroy when closed. // LUA_REGISTRYINDEX[&wxlua_lreg_topwindows_key][lightuserdata(&wxWindow)] = 1 --- 118,140 ---- // { wxLua type1 = weak fulluserdata, wxLua type2 = weak fulluserdata... } extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_weakobjects_key; ! // The key in the LUA_REGISTRYINDEX table that is a table of all ! // objects to delete that were added using wxluaO_addgcobject(). // Note that non wxObject classes use wxLUA_DECLARE_ENCAPSULATION so // the key is the object pointer and the value is the wxObject encapsulation. ! // Both the key and the value are the same if not encapsulated. // LUA_REGISTRYINDEX[&wxlua_lreg_gcobjects_key][lightuserdata(obj_ptr)] = // lightuserdata(wxObject derived class) extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_gcobjects_key; ! // The key in the LUA_REGISTRYINDEX table that is a table of all // wxLuaEventCallbacks that we've created. // LUA_REGISTRYINDEX[&wxlua_lreg_evtcallbacks_key][lightuserdata(&wxLuaEventCallback)] = // lightuserdata(&wxEvtHandler) extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_evtcallbacks_key; ! // The key in the LUA_REGISTRYINDEX table that is a table of wxWindow keys and ! // wxLuaWinDestroyCallback values that we've created. // LUA_REGISTRYINDEX[&wxlua_lreg_windestroycallbacks_key][lightuserdata(&wxWindow)] = // lightuserdata(wxLuaWinDestroyCallback) extern WXDLLIMPEXP_DATA_WXLUA(const char*) wxlua_lreg_windestroycallbacks_key; ! // The key in the LUA_REGISTRYINDEX table that is a table of all // top level wxWindows that we've created and need to destroy when closed. // LUA_REGISTRYINDEX[&wxlua_lreg_topwindows_key][lightuserdata(&wxWindow)] = 1 |