From: John L. <jr...@us...> - 2007-06-22 15:48:53
|
Update of /cvsroot/wxlua/wxLua/modules/wxbind/src In directory sc8-pr-cvs9.sourceforge.net:/tmp/cvs-serv23295/wxLua/modules/wxbind/src Modified Files: gdi.cpp Log Message: Fix for wxAnimation for MSW Fixes for controls.wx.lua for MSW Index: gdi.cpp =================================================================== RCS file: /cvsroot/wxlua/wxLua/modules/wxbind/src/gdi.cpp,v retrieving revision 1.77 retrieving revision 1.78 diff -C2 -d -r1.77 -r1.78 *** gdi.cpp 20 Jun 2007 22:57:36 -0000 1.77 --- gdi.cpp 22 Jun 2007 15:48:49 -0000 1.78 *************** *** 15020,15052 **** } - - #if (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) && ((defined(__WXMSW__)) && (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL)) - static wxLuaArgTag s_wxluatagArray_wxLua_wxAnimation_constructor2[] = { &s_wxluaarg_String, &s_wxluaarg_Integer, NULL }; - static int LUACALL wxLua_wxAnimation_constructor2(lua_State *L); - // static wxLuaBindCFunc s_wxluafunc_wxLua_wxAnimation_constructor2[1] = {{ wxLua_wxAnimation_constructor2, WXLUAMETHOD_CONSTRUCTOR, 1, 2, s_wxluatagArray_wxLua_wxAnimation_constructor2 }}; - // %msw wxAnimation(const wxString& name, wxAnimationType type = wxANIMATION_TYPE_ANY) - static int LUACALL wxLua_wxAnimation_constructor2(lua_State *L) - { - wxluabind_removetableforcall(L); - wxLuaState wxlState(L); - wxAnimation *returns; - // get number of arguments - int argCount = lua_gettop(L); - // wxAnimationType type = wxANIMATION_TYPE_ANY - wxAnimationType type = (argCount >= 2 ? (wxAnimationType)wxlua_getintegertype(L, 2) : wxANIMATION_TYPE_ANY); - // const wxString name - const wxString name = wxlState.GetwxStringType(1); - // call constructor - returns = new wxAnimation(name, type); - // add to tracked window list, it will check validity - wxlState.AddTrackedWindow(returns); - // push the constructed class pointer - wxlState.PushUserDataType(s_wxluatag_wxAnimation, returns); - - return 1; - } - - #endif // (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) && ((defined(__WXMSW__)) && (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL)) - static wxLuaArgTag s_wxluatagArray_wxLua_wxAnimation_constructor1[] = { &s_wxluatag_wxAnimation, NULL }; static int LUACALL wxLua_wxAnimation_constructor1(lua_State *L); --- 15020,15023 ---- *************** *** 15091,15104 **** ! #if ((wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) && ((defined(__WXMSW__)) && (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL)))||(wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) static int LUACALL wxLua_wxAnimation_constructor_overload(lua_State *L); // function overload table static wxLuaBindCFunc s_wxluafunc_wxLua_wxAnimation_constructor_overload[] = { ! { wxLua_wxAnimation_constructor_overload, WXLUAMETHOD_METHOD|WXLUAMETHOD_OVERLOAD, 0, 2, s_wxluaargArray_None }, ! ! #if (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) && ((defined(__WXMSW__)) && (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL)) ! { wxLua_wxAnimation_constructor2, WXLUAMETHOD_CONSTRUCTOR, 1, 2, s_wxluatagArray_wxLua_wxAnimation_constructor2 }, ! #endif // (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) && ((defined(__WXMSW__)) && (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL)) { wxLua_wxAnimation_constructor1, WXLUAMETHOD_CONSTRUCTOR, 1, 1, s_wxluatagArray_wxLua_wxAnimation_constructor1 }, { wxLua_wxAnimation_constructor, WXLUAMETHOD_CONSTRUCTOR, 0, 0, s_wxluaargArray_None }, --- 15062,15071 ---- ! #if (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) static int LUACALL wxLua_wxAnimation_constructor_overload(lua_State *L); // function overload table static wxLuaBindCFunc s_wxluafunc_wxLua_wxAnimation_constructor_overload[] = { ! { wxLua_wxAnimation_constructor_overload, WXLUAMETHOD_METHOD|WXLUAMETHOD_OVERLOAD, 0, 1, s_wxluaargArray_None }, { wxLua_wxAnimation_constructor1, WXLUAMETHOD_CONSTRUCTOR, 1, 1, s_wxluatagArray_wxLua_wxAnimation_constructor1 }, { wxLua_wxAnimation_constructor, WXLUAMETHOD_CONSTRUCTOR, 0, 0, s_wxluaargArray_None }, *************** *** 15113,15117 **** return wxlState.CallOverloadedFunction(&overload_method); } ! #endif // ((wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) && ((defined(__WXMSW__)) && (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL)))||(wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) // Map Lua Class Methods to C Binding Functions --- 15080,15084 ---- return wxlState.CallOverloadedFunction(&overload_method); } ! #endif // (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) // Map Lua Class Methods to C Binding Functions *************** *** 15137,15143 **** { "LoadFile", WXLUAMETHOD_METHOD, s_wxluafunc_wxLua_wxAnimation_LoadFile, 1, NULL }, ! #if ((wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) && ((defined(__WXMSW__)) && (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL)))||(wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) { "wxAnimation", WXLUAMETHOD_CONSTRUCTOR, s_wxluafunc_wxLua_wxAnimation_constructor_overload, s_wxluafunc_wxLua_wxAnimation_constructor_overload_count, 0 }, ! #endif // ((wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) && ((defined(__WXMSW__)) && (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL)))||(wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) { 0, 0, 0, 0 }, --- 15104,15110 ---- { "LoadFile", WXLUAMETHOD_METHOD, s_wxluafunc_wxLua_wxAnimation_LoadFile, 1, NULL }, ! #if (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) { "wxAnimation", WXLUAMETHOD_CONSTRUCTOR, s_wxluafunc_wxLua_wxAnimation_constructor_overload, s_wxluafunc_wxLua_wxAnimation_constructor_overload_count, 0 }, ! #endif // (wxCHECK_VERSION(2,8,0) && wxLUA_USE_wxAnimation && wxUSE_ANIMATIONCTRL) { 0, 0, 0, 0 }, |