// wxConfigPathChanger(const wxConfigBase *pContainer, const wxString& strEntry ); static int LUACALL wxLua_wxConfigPathChanger_constructor(lua_State *L) { // const wxString strEntry const wxString strEntry = wxlua_getwxStringtype(L, 2); // const wxConfigBase pContainer const wxConfigBase * pContainer = (const wxConfigBase *)wxluaT_getuserdatatype(L, 1, wxluatype_wxConfigBase); // call constructor wxConfigPathChanger* returns = new wxConfigPathChanger(pContainer, strEntry); // add to tracked memory list wxluaO_addgcobject(L, returns, wxluatype_wxConfigPathChanger); // push the constructed class pointer wxluaT_pushuserdatatype(L, returns, wxluatype_wxConfigPathChanger); return 1; }
// static wxProcess *Open(const wxString& cmd, int flags = wxEXEC_ASYNC) static int LUACALL wxLua_wxProcess_Open(lua_State *L) { // get number of arguments int argCount = lua_gettop(L); // int flags = wxEXEC_ASYNC int flags = (argCount >= 2 ? (int)wxlua_getnumbertype(L, 2) : wxEXEC_ASYNC); // const wxString cmd const wxString cmd = wxlua_getwxStringtype(L, 1); // call Open wxProcess* returns = (wxProcess*)wxProcess::Open(cmd, flags); // push the result datatype wxluaT_pushuserdatatype(L, returns, wxluatype_wxProcess); return 1; }
// wxlCanObjAddScript( double x, double y, const wxString& script ); static int LUACALL wxLua_wxlCanObjAddScript_constructor(lua_State *L) { // const wxString script const wxString script = wxlua_getwxStringtype(L, 3); // double y double y = (double)wxlua_getnumbertype(L, 2); // double x double x = (double)wxlua_getnumbertype(L, 1); // call constructor wxlCanObjAddScript* returns = new wxlCanObjAddScript(x, y, script); // push the constructed class pointer wxluaT_pushuserdatatype(L, returns, wxluatype_wxlCanObjAddScript); return 1; }
// static wxLuaBindCFunc s_wxluafunc_wxLua_wxConfigBase_Write1[1] = {{ wxLua_wxConfigBase_Write1, WXLUAMETHOD_METHOD, 3, 3, s_wxluatypeArray_wxLua_wxConfigBase_Write1 }}; // bool Write(const wxString &key, double value) static int LUACALL wxLua_wxConfigBase_Write1(lua_State *L) { // double value double value = (double)wxlua_getnumbertype(L, 3); // const wxString key const wxString key = wxlua_getwxStringtype(L, 2); // get this wxConfigBase * self = (wxConfigBase *)wxluaT_getuserdatatype(L, 1, wxluatype_wxConfigBase); // call Write bool returns = (self->Write(key, value)); // push the result flag lua_pushboolean(L, returns); return 1; }
// wxToolBar* LoadToolBar(wxWindow *parent, const wxString& name); static int LUACALL wxLua_wxXmlResource_LoadToolBar(lua_State *L) { // const wxString name const wxString name = wxlua_getwxStringtype(L, 3); // wxWindow parent wxWindow * parent = (wxWindow *)wxluaT_getuserdatatype(L, 2, wxluatype_wxWindow); // get this wxXmlResource * self = (wxXmlResource *)wxluaT_getuserdatatype(L, 1, wxluatype_wxXmlResource); // call LoadToolBar wxToolBar* returns = (wxToolBar*)self->LoadToolBar(parent, name); // push the result datatype wxluaT_pushuserdatatype(L, returns, wxluatype_wxToolBar); return 1; }
// static int GetXRCID(const wxString &stringID, int value_if_not_found = wxID_NONE); static int LUACALL wxLua_wxXmlResource_GetXRCID(lua_State *L) { // get number of arguments int argCount = lua_gettop(L); // int value_if_not_found = wxID_NONE int value_if_not_found = (argCount >= 2 ? (int)wxlua_getnumbertype(L, 2) : wxID_NONE); // const wxString stringID const wxString stringID = wxlua_getwxStringtype(L, 1); // call GetXRCID int returns = (wxXmlResource::GetXRCID(stringID, value_if_not_found)); // push the result number lua_pushnumber(L, returns); return 1; }
// wxIcon LoadIcon(const wxString& name); static int LUACALL wxLua_wxXmlResource_LoadIcon(lua_State *L) { // const wxString name const wxString name = wxlua_getwxStringtype(L, 2); // get this wxXmlResource * self = (wxXmlResource *)wxluaT_getuserdatatype(L, 1, wxluatype_wxXmlResource); // call LoadIcon // allocate a new object using the copy constructor wxIcon* returns = new wxIcon(self->LoadIcon(name)); // add the new object to the tracked memory list wxluaO_addgcobject(L, returns, wxluatype_wxIcon); // push the result datatype wxluaT_pushuserdatatype(L, returns, wxluatype_wxIcon); return 1; }
// bool DeleteEntry(const wxString& key, bool bDeleteGroupIfEmpty = true ); static int LUACALL wxLua_wxConfigBase_DeleteEntry(lua_State *L) { // get number of arguments int argCount = lua_gettop(L); // bool bDeleteGroupIfEmpty = true bool bDeleteGroupIfEmpty = (argCount >= 3 ? wxlua_getbooleantype(L, 3) : true); // const wxString key const wxString key = wxlua_getwxStringtype(L, 2); // get this wxConfigBase * self = (wxConfigBase *)wxluaT_getuserdatatype(L, 1, wxluatype_wxConfigBase); // call DeleteEntry bool returns = (self->DeleteEntry(key, bDeleteGroupIfEmpty)); // push the result flag lua_pushboolean(L, returns); return 1; }
// wxBusyInfo(const wxString& message, wxWindow *parent = NULL) static int LUACALL wxLua_wxBusyInfo_constructor(lua_State *L) { // get number of arguments int argCount = lua_gettop(L); // wxWindow parent = NULL wxWindow * parent = (argCount >= 2 ? (wxWindow *)wxluaT_getuserdatatype(L, 2, wxluatype_wxWindow) : NULL); // const wxString message const wxString message = wxlua_getwxStringtype(L, 1); // call constructor wxBusyInfo* returns = new wxBusyInfo(message, parent); // add to tracked memory list wxluaO_addgcobject(L, returns, wxluatype_wxBusyInfo); // push the constructed class pointer wxluaT_pushuserdatatype(L, returns, wxluatype_wxBusyInfo); return 1; }
// static wxLuaBindCFunc s_wxluafunc_wxLua_wxXmlResource_constructor[1] = {{ wxLua_wxXmlResource_constructor, WXLUAMETHOD_CONSTRUCTOR, 0, 2, s_wxluatypeArray_wxLua_wxXmlResource_constructor }}; // wxXmlResource(int flags = wxXRC_USE_LOCALE, const wxString& domain = ""); static int LUACALL wxLua_wxXmlResource_constructor(lua_State *L) { // get number of arguments int argCount = lua_gettop(L); // const wxString domain = "" const wxString domain = (argCount >= 2 ? wxlua_getwxStringtype(L, 2) : wxString(wxEmptyString)); // int flags = wxXRC_USE_LOCALE int flags = (argCount >= 1 ? (int)wxlua_getnumbertype(L, 1) : wxXRC_USE_LOCALE); // call constructor wxXmlResource* returns = new wxXmlResource(flags, domain); // add to tracked memory list wxluaO_addgcobject(L, returns, wxluatype_wxXmlResource); // push the constructed class pointer wxluaT_pushuserdatatype(L, returns, wxluatype_wxXmlResource); return 1; }
// static wxLuaBindCFunc s_wxluafunc_wxLua_wxXmlResource_LoadPanel1[1] = {{ wxLua_wxXmlResource_LoadPanel1, WXLUAMETHOD_METHOD, 4, 4, s_wxluatypeArray_wxLua_wxXmlResource_LoadPanel1 }}; // bool LoadPanel(wxPanel *panel, wxWindow *parent, const wxString &name); static int LUACALL wxLua_wxXmlResource_LoadPanel1(lua_State *L) { // const wxString name const wxString name = wxlua_getwxStringtype(L, 4); // wxWindow parent wxWindow * parent = (wxWindow *)wxluaT_getuserdatatype(L, 3, wxluatype_wxWindow); // wxPanel panel wxPanel * panel = (wxPanel *)wxluaT_getuserdatatype(L, 2, wxluatype_wxPanel); // get this wxXmlResource * self = (wxXmlResource *)wxluaT_getuserdatatype(L, 1, wxluatype_wxXmlResource); // call LoadPanel bool returns = (self->LoadPanel(panel, parent, name)); // push the result flag lua_pushboolean(L, returns); return 1; }
// static wxLuaBindCFunc s_wxluafunc_wxLua_wxXmlResource_LoadDialog1[1] = {{ wxLua_wxXmlResource_LoadDialog1, WXLUAMETHOD_METHOD, 4, 4, s_wxluatypeArray_wxLua_wxXmlResource_LoadDialog1 }}; // bool LoadDialog(wxDialog* dlg, wxWindow *parent, const wxString &name); static int LUACALL wxLua_wxXmlResource_LoadDialog1(lua_State *L) { // const wxString name const wxString name = wxlua_getwxStringtype(L, 4); // wxWindow parent wxWindow * parent = (wxWindow *)wxluaT_getuserdatatype(L, 3, wxluatype_wxWindow); // wxDialog dlg wxDialog * dlg = (wxDialog *)wxluaT_getuserdatatype(L, 2, wxluatype_wxDialog); // get this wxXmlResource * self = (wxXmlResource *)wxluaT_getuserdatatype(L, 1, wxluatype_wxXmlResource); // call LoadDialog bool returns = (self->LoadDialog(dlg, parent, name)); // push the result flag lua_pushboolean(L, returns); return 1; }
// bool AttachUnknownControl(const wxString& name, wxWindow* control, wxWindow* parent = NULL); static int LUACALL wxLua_wxXmlResource_AttachUnknownControl(lua_State *L) { // get number of arguments int argCount = lua_gettop(L); // wxWindow parent = NULL wxWindow * parent = (argCount >= 4 ? (wxWindow *)wxluaT_getuserdatatype(L, 4, wxluatype_wxWindow) : NULL); // wxWindow control wxWindow * control = (wxWindow *)wxluaT_getuserdatatype(L, 3, wxluatype_wxWindow); // const wxString name const wxString name = wxlua_getwxStringtype(L, 2); // get this wxXmlResource * self = (wxXmlResource *)wxluaT_getuserdatatype(L, 1, wxluatype_wxXmlResource); // call AttachUnknownControl bool returns = (self->AttachUnknownControl(name, control, parent)); // push the result flag lua_pushboolean(L, returns); return 1; }
// static wxLuaBindCFunc s_wxluafunc_wxLua_wxConfigBase_Read1[1] = {{ wxLua_wxConfigBase_Read1, WXLUAMETHOD_METHOD, 3, 3, s_wxluatypeArray_wxLua_wxConfigBase_Read1 }}; // %override wxLua_wxConfigBase_ReadFloat // %rename ReadFloat bool Read(const wxString& key, double* d, double defaultVal = 0) const static int LUACALL wxLua_wxConfigBase_ReadFloat(lua_State *L) { double returns = 0; // get number of arguments int argCount = lua_gettop(L); // double defaultVal = 0 double defaultVal = (argCount >= 3 ? (double)wxlua_getnumbertype(L, 3) : 0); // const wxString& key wxString key = wxlua_getwxStringtype(L, 2); // get this wxConfigBase *self = (wxConfigBase *)wxluaT_getuserdatatype(L, 1, wxluatype_wxConfigBase); // call Read bool ret = self->Read(key, &returns, defaultVal); // push the result bool lua_pushboolean(L, ret); // push the result number lua_pushnumber(L, returns); // return the number of parameters return 2; }
// %override wxLua_wxConfigBase_GetFirstGroup // bool GetFirstGroup(wxString& str, long& index) const static int LUACALL wxLua_wxConfigBase_GetFirstGroup(lua_State *L) { // get number of arguments int argCount = lua_gettop(L); // these are optional and are not used anyway long index = (argCount >= 3 ? (long)wxlua_getintegertype(L, 3) : 0); wxString str = (argCount >= 2 ? wxlua_getwxStringtype(L, 2) : wxString(wxEmptyString)); // get this wxConfig *self = (wxConfig *)wxluaT_getuserdatatype(L, 1, wxluatype_wxConfigBase); // call GetFirstGroup bool returns = self->GetFirstGroup(str, index); // push the result number lua_pushboolean(L, returns); // push the result string wxlua_pushwxString(L, str); // push the next index lua_pushnumber(L, index); // return the number of parameters return 3; }
// wxLogWindow(wxWindow *pParent, const wxString& szTitle, bool bShow = true, bool bPassToOld = true); static int LUACALL wxLua_wxLogWindow_constructor(lua_State *L) { // get number of arguments int argCount = lua_gettop(L); // bool bPassToOld = true bool bPassToOld = (argCount >= 4 ? wxlua_getbooleantype(L, 4) : true); // bool bShow = true bool bShow = (argCount >= 3 ? wxlua_getbooleantype(L, 3) : true); // const wxString szTitle const wxString szTitle = wxlua_getwxStringtype(L, 2); // wxWindow pParent wxWindow * pParent = (wxWindow *)wxluaT_getuserdatatype(L, 1, wxluatype_wxWindow); // call constructor wxLogWindow* returns = new wxLogWindow(pParent, szTitle, bShow, bPassToOld); // add to tracked memory list wxluaO_addgcobject(L, returns, wxluatype_wxLogWindow); // push the constructed class pointer wxluaT_pushuserdatatype(L, returns, wxluatype_wxLogWindow); return 1; }