X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/14afa2cbca535ad8fabc8f7ef6792f2d6dc01741..71aba8333cc915afff9e740c944f7fa7247abacb:/wxPython/src/msw/controls2.cpp?ds=inline diff --git a/wxPython/src/msw/controls2.cpp b/wxPython/src/msw/controls2.cpp index 13074c0dc7..0802230f15 100644 --- a/wxPython/src/msw/controls2.cpp +++ b/wxPython/src/msw/controls2.cpp @@ -19,6 +19,8 @@ /* Implementation : PYTHON */ #define SWIGPYTHON +#include "Python.h" + #include #include /* Definitions for Windows/Unix exporting */ @@ -36,12 +38,9 @@ # define SWIGEXPORT(a) a #endif -#include "Python.h" - #ifdef __cplusplus extern "C" { #endif - extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -64,6 +63,8 @@ extern PyObject *SWIG_newvarlink(void); #include #include +#include "pytree.h" + static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; @@ -91,11 +92,17 @@ static PyObject* t_output_helper(PyObject* target, PyObject* o) { return target; } -#if PYTHON_API_VERSION >= 1009 - static char* wxStringErrorMsg = "String or Unicode type required"; -#else - static char* wxStringErrorMsg = "String type required"; -#endif + // Put some wx default wxChar* values into wxStrings. + const wxChar* wxListCtrlNameStr = _T("wxListCtrl"); + DECLARE_DEF_STRING(ListCtrlNameStr); + + const wxChar* wx_TreeCtrlNameStr = _T("wxTreeCtrl"); + DECLARE_DEF_STRING(_TreeCtrlNameStr); + DECLARE_DEF_STRING(DirDialogDefaultFolderStr); + + static const wxString wxPyEmptyString(wxT("")); + + static const long longzero = 0; // C++ Version of a Python aware class class wxPyListCtrl : public wxListCtrl { DECLARE_ABSTRACT_CLASS(wxPyListCtrl); @@ -106,7 +113,7 @@ public: const wxSize& size, long style, const wxValidator& validator, - char* name) : + const wxString& name) : wxListCtrl(parent, id, pos, size, style, validator, name) {} bool Create(wxWindow* parent, wxWindowID id, @@ -114,7 +121,7 @@ public: const wxSize& size, long style, const wxValidator& validator, - char* name) { + const wxString& name) { return wxListCtrl::Create(parent, id, pos, size, style, validator, name); } @@ -148,37 +155,6 @@ IMP_PYCALLBACK_LISTATTR_LONG(wxPyListCtrl, wxListCtrl, OnGetItemAttr); return retval; } - -class wxPyTreeItemData : public wxTreeItemData { -public: - wxPyTreeItemData(PyObject* obj = NULL) { - if (obj == NULL) - obj = Py_None; - Py_INCREF(obj); - m_obj = obj; - } - - ~wxPyTreeItemData() { - wxPyBeginBlockThreads(); - Py_DECREF(m_obj); - wxPyEndBlockThreads(); - } - - PyObject* GetData() { - Py_INCREF(m_obj); - return m_obj; - } - - void SetData(PyObject* obj) { - wxPyBeginBlockThreads(); - Py_DECREF(m_obj); - wxPyEndBlockThreads(); - m_obj = obj; - Py_INCREF(obj); - } - - PyObject* m_obj; -}; // C++ version of Python aware wxTreeCtrl class wxPyTreeCtrl : public wxTreeCtrl { DECLARE_ABSTRACT_CLASS(wxPyTreeCtrl); @@ -189,7 +165,7 @@ public: const wxSize& size, long style, const wxValidator& validator, - char* name) : + const wxString& name) : wxTreeCtrl(parent, id, pos, size, style, validator, name) {} bool Create(wxWindow *parent, wxWindowID id, @@ -197,7 +173,7 @@ public: const wxSize& size, long style, const wxValidator& validator, - char* name) { + const wxString& name) { return wxTreeCtrl::Create(parent, id, pos, size, style, validator, name); } @@ -207,11 +183,13 @@ public: int rval = 0; bool found; wxPyBeginBlockThreads(); - if ((found = m_myInst.findCallback("OnCompareItems"))) - rval = m_myInst.callCallback(Py_BuildValue( - "(OO)", - wxPyConstructObject((void*)&item1, "wxTreeItemId"), - wxPyConstructObject((void*)&item2, "wxTreeItemId"))); + if ((found = m_myInst.findCallback("OnCompareItems"))) { + PyObject *o1 = wxPyConstructObject((void*)&item1, wxT("wxTreeItemId")); + PyObject *o2 = wxPyConstructObject((void*)&item2, wxT("wxTreeItemId")); + rval = m_myInst.callCallback(Py_BuildValue("(OO)",o1,o2)); + Py_DECREF(o1); + Py_DECREF(o2); + } wxPyEndBlockThreads(); if (! found) rval = wxTreeCtrl::OnCompareItems(item1, item2); @@ -256,15 +234,14 @@ static PyObject *_wrap_new_wxListItemAttr(PyObject *self, PyObject *args, PyObje return NULL; } if (_argo2) { - if (_argo2 == Py_None) { _arg2 = NULL; } - else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxFont_p")) { + if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxFont_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of new_wxListItemAttr. Expected _wxFont_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxListItemAttr *)new_wxListItemAttr(*_arg0,*_arg1,*_arg2); + _result = (wxListItemAttr *)new_wxListItemAttr(*_arg0,*_arg1,*_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -305,7 +282,7 @@ static PyObject *_wrap_wxListItemAttr_SetTextColour(PyObject *self, PyObject *ar } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItemAttr_SetTextColour(_arg0,*_arg1); + wxListItemAttr_SetTextColour(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -341,7 +318,7 @@ static PyObject *_wrap_wxListItemAttr_SetBackgroundColour(PyObject *self, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItemAttr_SetBackgroundColour(_arg0,*_arg1); + wxListItemAttr_SetBackgroundColour(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -370,15 +347,14 @@ static PyObject *_wrap_wxListItemAttr_SetFont(PyObject *self, PyObject *args, Py } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxFont_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxFont_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxListItemAttr_SetFont. Expected _wxFont_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItemAttr_SetFont(_arg0,*_arg1); + wxListItemAttr_SetFont(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -407,7 +383,7 @@ static PyObject *_wrap_wxListItemAttr_HasTextColour(PyObject *self, PyObject *ar } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListItemAttr_HasTextColour(_arg0); + _result = (bool )wxListItemAttr_HasTextColour(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -435,7 +411,7 @@ static PyObject *_wrap_wxListItemAttr_HasBackgroundColour(PyObject *self, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListItemAttr_HasBackgroundColour(_arg0); + _result = (bool )wxListItemAttr_HasBackgroundColour(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -463,7 +439,7 @@ static PyObject *_wrap_wxListItemAttr_HasFont(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListItemAttr_HasFont(_arg0); + _result = (bool )wxListItemAttr_HasFont(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -492,7 +468,7 @@ static PyObject *_wrap_wxListItemAttr_GetTextColour(PyObject *self, PyObject *ar } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxColour (wxListItemAttr_GetTextColour(_arg0)); + _result = new wxColour (wxListItemAttr_GetTextColour(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -522,7 +498,7 @@ static PyObject *_wrap_wxListItemAttr_GetBackgroundColour(PyObject *self, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxColour (wxListItemAttr_GetBackgroundColour(_arg0)); + _result = new wxColour (wxListItemAttr_GetBackgroundColour(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -552,7 +528,7 @@ static PyObject *_wrap_wxListItemAttr_GetFont(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxFont (wxListItemAttr_GetFont(_arg0)); + _result = new wxFont (wxListItemAttr_GetFont(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -581,7 +557,7 @@ static PyObject *_wrap_new_wxListItem(PyObject *self, PyObject *args, PyObject * return NULL; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxListItem *)new_wxListItem(); + _result = (wxListItem *)new_wxListItem(); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -614,7 +590,7 @@ static PyObject *_wrap_delete_wxListItem(PyObject *self, PyObject *args, PyObjec } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - delete_wxListItem(_arg0); + delete_wxListItem(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -642,7 +618,7 @@ static PyObject *_wrap_wxListItem_Clear(PyObject *self, PyObject *args, PyObject } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_Clear(_arg0); + wxListItem_Clear(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -670,7 +646,7 @@ static PyObject *_wrap_wxListItem_ClearAttributes(PyObject *self, PyObject *args } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_ClearAttributes(_arg0); + wxListItem_ClearAttributes(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -699,7 +675,7 @@ static PyObject *_wrap_wxListItem_SetMask(PyObject *self, PyObject *args, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_SetMask(_arg0,_arg1); + wxListItem_SetMask(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -728,7 +704,7 @@ static PyObject *_wrap_wxListItem_SetId(PyObject *self, PyObject *args, PyObject } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_SetId(_arg0,_arg1); + wxListItem_SetId(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -757,7 +733,7 @@ static PyObject *_wrap_wxListItem_SetColumn(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_SetColumn(_arg0,_arg1); + wxListItem_SetColumn(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -786,7 +762,7 @@ static PyObject *_wrap_wxListItem_SetState(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_SetState(_arg0,_arg1); + wxListItem_SetState(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -815,7 +791,7 @@ static PyObject *_wrap_wxListItem_SetStateMask(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_SetStateMask(_arg0,_arg1); + wxListItem_SetStateMask(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -844,26 +820,13 @@ static PyObject *_wrap_wxListItem_SetText(PyObject *self, PyObject *args, PyObje } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg1 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) return NULL; - } - _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_SetText(_arg0,*_arg1); + wxListItem_SetText(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -896,7 +859,7 @@ static PyObject *_wrap_wxListItem_SetImage(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_SetImage(_arg0,_arg1); + wxListItem_SetImage(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -925,7 +888,7 @@ static PyObject *_wrap_wxListItem_SetData(PyObject *self, PyObject *args, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_SetData(_arg0,_arg1); + wxListItem_SetData(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -954,7 +917,7 @@ static PyObject *_wrap_wxListItem_SetWidth(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_SetWidth(_arg0,_arg1); + wxListItem_SetWidth(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -983,7 +946,7 @@ static PyObject *_wrap_wxListItem_SetAlign(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_SetAlign(_arg0,_arg1); + wxListItem_SetAlign(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1019,7 +982,7 @@ static PyObject *_wrap_wxListItem_SetTextColour(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_SetTextColour(_arg0,*_arg1); + wxListItem_SetTextColour(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1055,7 +1018,7 @@ static PyObject *_wrap_wxListItem_SetBackgroundColour(PyObject *self, PyObject * } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_SetBackgroundColour(_arg0,*_arg1); + wxListItem_SetBackgroundColour(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1084,15 +1047,14 @@ static PyObject *_wrap_wxListItem_SetFont(PyObject *self, PyObject *args, PyObje } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxFont_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxFont_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxListItem_SetFont. Expected _wxFont_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListItem_SetFont(_arg0,*_arg1); + wxListItem_SetFont(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1121,7 +1083,7 @@ static PyObject *_wrap_wxListItem_GetMask(PyObject *self, PyObject *args, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListItem_GetMask(_arg0); + _result = (long )wxListItem_GetMask(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1149,7 +1111,7 @@ static PyObject *_wrap_wxListItem_GetId(PyObject *self, PyObject *args, PyObject } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListItem_GetId(_arg0); + _result = (long )wxListItem_GetId(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1177,7 +1139,7 @@ static PyObject *_wrap_wxListItem_GetColumn(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListItem_GetColumn(_arg0); + _result = (int )wxListItem_GetColumn(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1205,7 +1167,7 @@ static PyObject *_wrap_wxListItem_GetState(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListItem_GetState(_arg0); + _result = (long )wxListItem_GetState(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1233,13 +1195,17 @@ static PyObject *_wrap_wxListItem_GetText(PyObject *self, PyObject *args, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - const wxString & _result_ref = wxListItem_GetText(_arg0); + const wxString & _result_ref = wxListItem_GetText(_arg0); _result = (wxString *) &_result_ref; wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } return _resultobj; } @@ -1264,7 +1230,7 @@ static PyObject *_wrap_wxListItem_GetImage(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListItem_GetImage(_arg0); + _result = (int )wxListItem_GetImage(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1292,7 +1258,7 @@ static PyObject *_wrap_wxListItem_GetData(PyObject *self, PyObject *args, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListItem_GetData(_arg0); + _result = (long )wxListItem_GetData(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1320,7 +1286,7 @@ static PyObject *_wrap_wxListItem_GetWidth(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListItem_GetWidth(_arg0); + _result = (int )wxListItem_GetWidth(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1348,7 +1314,7 @@ static PyObject *_wrap_wxListItem_GetAlign(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxListColumnFormat )wxListItem_GetAlign(_arg0); + _result = (wxListColumnFormat )wxListItem_GetAlign(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1377,7 +1343,7 @@ static PyObject *_wrap_wxListItem_GetAttributes(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxListItemAttr *)wxListItem_GetAttributes(_arg0); + _result = (wxListItemAttr *)wxListItem_GetAttributes(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1411,7 +1377,7 @@ static PyObject *_wrap_wxListItem_HasAttributes(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListItem_HasAttributes(_arg0); + _result = (bool )wxListItem_HasAttributes(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1440,7 +1406,7 @@ static PyObject *_wrap_wxListItem_GetTextColour(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxColour (wxListItem_GetTextColour(_arg0)); + _result = new wxColour (wxListItem_GetTextColour(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1470,7 +1436,7 @@ static PyObject *_wrap_wxListItem_GetBackgroundColour(PyObject *self, PyObject * } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxColour (wxListItem_GetBackgroundColour(_arg0)); + _result = new wxColour (wxListItem_GetBackgroundColour(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1500,7 +1466,7 @@ static PyObject *_wrap_wxListItem_GetFont(PyObject *self, PyObject *args, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxFont (wxListItem_GetFont(_arg0)); + _result = new wxFont (wxListItem_GetFont(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1530,7 +1496,7 @@ static PyObject *_wrap_wxListItem_m_mask_set(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListItem_m_mask_set(_arg0,_arg1); + _result = (long )wxListItem_m_mask_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1558,7 +1524,7 @@ static PyObject *_wrap_wxListItem_m_mask_get(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListItem_m_mask_get(_arg0); + _result = (long )wxListItem_m_mask_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1587,7 +1553,7 @@ static PyObject *_wrap_wxListItem_m_itemId_set(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListItem_m_itemId_set(_arg0,_arg1); + _result = (long )wxListItem_m_itemId_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1615,7 +1581,7 @@ static PyObject *_wrap_wxListItem_m_itemId_get(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListItem_m_itemId_get(_arg0); + _result = (long )wxListItem_m_itemId_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1644,7 +1610,7 @@ static PyObject *_wrap_wxListItem_m_col_set(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListItem_m_col_set(_arg0,_arg1); + _result = (int )wxListItem_m_col_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1672,7 +1638,7 @@ static PyObject *_wrap_wxListItem_m_col_get(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListItem_m_col_get(_arg0); + _result = (int )wxListItem_m_col_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1701,7 +1667,7 @@ static PyObject *_wrap_wxListItem_m_state_set(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListItem_m_state_set(_arg0,_arg1); + _result = (long )wxListItem_m_state_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1729,7 +1695,7 @@ static PyObject *_wrap_wxListItem_m_state_get(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListItem_m_state_get(_arg0); + _result = (long )wxListItem_m_state_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1758,7 +1724,7 @@ static PyObject *_wrap_wxListItem_m_stateMask_set(PyObject *self, PyObject *args } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListItem_m_stateMask_set(_arg0,_arg1); + _result = (long )wxListItem_m_stateMask_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1786,7 +1752,7 @@ static PyObject *_wrap_wxListItem_m_stateMask_get(PyObject *self, PyObject *args } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListItem_m_stateMask_get(_arg0); + _result = (long )wxListItem_m_stateMask_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1815,31 +1781,22 @@ static PyObject *_wrap_wxListItem_m_text_set(PyObject *self, PyObject *args, PyO } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1) + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) return NULL; - _arg1 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxString *)wxListItem_m_text_set(_arg0,_arg1); + _result = (wxString *)wxListItem_m_text_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } { if (_obj1) @@ -1868,12 +1825,16 @@ static PyObject *_wrap_wxListItem_m_text_get(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxString *)wxListItem_m_text_get(_arg0); + _result = (wxString *)wxListItem_m_text_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } return _resultobj; } @@ -1899,7 +1860,7 @@ static PyObject *_wrap_wxListItem_m_image_set(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListItem_m_image_set(_arg0,_arg1); + _result = (int )wxListItem_m_image_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1927,7 +1888,7 @@ static PyObject *_wrap_wxListItem_m_image_get(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListItem_m_image_get(_arg0); + _result = (int )wxListItem_m_image_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1956,7 +1917,7 @@ static PyObject *_wrap_wxListItem_m_data_set(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListItem_m_data_set(_arg0,_arg1); + _result = (long )wxListItem_m_data_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1984,7 +1945,7 @@ static PyObject *_wrap_wxListItem_m_data_get(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListItem_m_data_get(_arg0); + _result = (long )wxListItem_m_data_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2013,7 +1974,7 @@ static PyObject *_wrap_wxListItem_m_format_set(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListItem_m_format_set(_arg0,_arg1); + _result = (int )wxListItem_m_format_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2041,7 +2002,7 @@ static PyObject *_wrap_wxListItem_m_format_get(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListItem_m_format_get(_arg0); + _result = (int )wxListItem_m_format_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2070,7 +2031,7 @@ static PyObject *_wrap_wxListItem_m_width_set(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListItem_m_width_set(_arg0,_arg1); + _result = (int )wxListItem_m_width_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2098,7 +2059,7 @@ static PyObject *_wrap_wxListItem_m_width_get(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListItem_m_width_get(_arg0); + _result = (int )wxListItem_m_width_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2152,7 +2113,7 @@ static PyObject *_wrap_new_wxListEvent(PyObject *self, PyObject *args, PyObject return NULL; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxListEvent *)new_wxListEvent(_arg0,_arg1); + _result = (wxListEvent *)new_wxListEvent(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2166,35 +2127,6 @@ static PyObject *_wrap_new_wxListEvent(PyObject *self, PyObject *args, PyObject return _resultobj; } -#define wxListEvent_m_code_set(_swigobj,_swigval) (_swigobj->m_code = _swigval,_swigval) -static PyObject *_wrap_wxListEvent_m_code_set(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject * _resultobj; - int _result; - wxListEvent * _arg0; - int _arg1; - PyObject * _argo0 = 0; - char *_kwnames[] = { "self","m_code", NULL }; - - self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxListEvent_m_code_set",_kwnames,&_argo0,&_arg1)) - return NULL; - if (_argo0) { - if (_argo0 == Py_None) { _arg0 = NULL; } - else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxListEvent_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListEvent_m_code_set. Expected _wxListEvent_p."); - return NULL; - } - } -{ - PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListEvent_m_code_set(_arg0,_arg1); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) return NULL; -} _resultobj = Py_BuildValue("i",_result); - return _resultobj; -} - #define wxListEvent_m_code_get(_swigobj) ((int ) _swigobj->m_code) static PyObject *_wrap_wxListEvent_m_code_get(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -2215,7 +2147,7 @@ static PyObject *_wrap_wxListEvent_m_code_get(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListEvent_m_code_get(_arg0); + _result = (int )wxListEvent_m_code_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2223,35 +2155,6 @@ static PyObject *_wrap_wxListEvent_m_code_get(PyObject *self, PyObject *args, Py return _resultobj; } -#define wxListEvent_m_oldItemIndex_set(_swigobj,_swigval) (_swigobj->m_oldItemIndex = _swigval,_swigval) -static PyObject *_wrap_wxListEvent_m_oldItemIndex_set(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject * _resultobj; - long _result; - wxListEvent * _arg0; - long _arg1; - PyObject * _argo0 = 0; - char *_kwnames[] = { "self","m_oldItemIndex", NULL }; - - self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Ol:wxListEvent_m_oldItemIndex_set",_kwnames,&_argo0,&_arg1)) - return NULL; - if (_argo0) { - if (_argo0 == Py_None) { _arg0 = NULL; } - else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxListEvent_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListEvent_m_oldItemIndex_set. Expected _wxListEvent_p."); - return NULL; - } - } -{ - PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListEvent_m_oldItemIndex_set(_arg0,_arg1); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) return NULL; -} _resultobj = Py_BuildValue("l",_result); - return _resultobj; -} - #define wxListEvent_m_oldItemIndex_get(_swigobj) ((long ) _swigobj->m_oldItemIndex) static PyObject *_wrap_wxListEvent_m_oldItemIndex_get(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -2272,36 +2175,7 @@ static PyObject *_wrap_wxListEvent_m_oldItemIndex_get(PyObject *self, PyObject * } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListEvent_m_oldItemIndex_get(_arg0); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) return NULL; -} _resultobj = Py_BuildValue("l",_result); - return _resultobj; -} - -#define wxListEvent_m_itemIndex_set(_swigobj,_swigval) (_swigobj->m_itemIndex = _swigval,_swigval) -static PyObject *_wrap_wxListEvent_m_itemIndex_set(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject * _resultobj; - long _result; - wxListEvent * _arg0; - long _arg1; - PyObject * _argo0 = 0; - char *_kwnames[] = { "self","m_itemIndex", NULL }; - - self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Ol:wxListEvent_m_itemIndex_set",_kwnames,&_argo0,&_arg1)) - return NULL; - if (_argo0) { - if (_argo0 == Py_None) { _arg0 = NULL; } - else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxListEvent_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListEvent_m_itemIndex_set. Expected _wxListEvent_p."); - return NULL; - } - } -{ - PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListEvent_m_itemIndex_set(_arg0,_arg1); + _result = (long )wxListEvent_m_oldItemIndex_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2329,7 +2203,7 @@ static PyObject *_wrap_wxListEvent_m_itemIndex_get(PyObject *self, PyObject *arg } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListEvent_m_itemIndex_get(_arg0); + _result = (long )wxListEvent_m_itemIndex_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2337,35 +2211,6 @@ static PyObject *_wrap_wxListEvent_m_itemIndex_get(PyObject *self, PyObject *arg return _resultobj; } -#define wxListEvent_m_col_set(_swigobj,_swigval) (_swigobj->m_col = _swigval,_swigval) -static PyObject *_wrap_wxListEvent_m_col_set(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject * _resultobj; - int _result; - wxListEvent * _arg0; - int _arg1; - PyObject * _argo0 = 0; - char *_kwnames[] = { "self","m_col", NULL }; - - self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxListEvent_m_col_set",_kwnames,&_argo0,&_arg1)) - return NULL; - if (_argo0) { - if (_argo0 == Py_None) { _arg0 = NULL; } - else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxListEvent_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListEvent_m_col_set. Expected _wxListEvent_p."); - return NULL; - } - } -{ - PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListEvent_m_col_set(_arg0,_arg1); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) return NULL; -} _resultobj = Py_BuildValue("i",_result); - return _resultobj; -} - #define wxListEvent_m_col_get(_swigobj) ((int ) _swigobj->m_col) static PyObject *_wrap_wxListEvent_m_col_get(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -2386,7 +2231,7 @@ static PyObject *_wrap_wxListEvent_m_col_get(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListEvent_m_col_get(_arg0); + _result = (int )wxListEvent_m_col_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2394,49 +2239,6 @@ static PyObject *_wrap_wxListEvent_m_col_get(PyObject *self, PyObject *args, PyO return _resultobj; } -#define wxListEvent_m_pointDrag_set(_swigobj,_swigval) (_swigobj->m_pointDrag = *(_swigval),_swigval) -static PyObject *_wrap_wxListEvent_m_pointDrag_set(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject * _resultobj; - wxPoint * _result; - wxListEvent * _arg0; - wxPoint * _arg1; - PyObject * _argo0 = 0; - wxPoint temp; - PyObject * _obj1 = 0; - char *_kwnames[] = { "self","m_pointDrag", NULL }; - char _ptemp[128]; - - self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxListEvent_m_pointDrag_set",_kwnames,&_argo0,&_obj1)) - return NULL; - if (_argo0) { - if (_argo0 == Py_None) { _arg0 = NULL; } - else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxListEvent_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListEvent_m_pointDrag_set. Expected _wxListEvent_p."); - return NULL; - } - } -{ - _arg1 = &temp; - if (! wxPoint_helper(_obj1, &_arg1)) - return NULL; -} -{ - PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxPoint *)wxListEvent_m_pointDrag_set(_arg0,_arg1); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) return NULL; -} if (_result) { - SWIG_MakePtr(_ptemp, (char *) _result,"_wxPoint_p"); - _resultobj = Py_BuildValue("s",_ptemp); - } else { - Py_INCREF(Py_None); - _resultobj = Py_None; - } - return _resultobj; -} - #define wxListEvent_m_pointDrag_get(_swigobj) (&_swigobj->m_pointDrag) static PyObject *_wrap_wxListEvent_m_pointDrag_get(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -2458,7 +2260,7 @@ static PyObject *_wrap_wxListEvent_m_pointDrag_get(PyObject *self, PyObject *arg } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxPoint *)wxListEvent_m_pointDrag_get(_arg0); + _result = (wxPoint *)wxListEvent_m_pointDrag_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2472,43 +2274,6 @@ static PyObject *_wrap_wxListEvent_m_pointDrag_get(PyObject *self, PyObject *arg return _resultobj; } -#define wxListEvent_m_item_set(_swigobj,_swigval) (_swigobj->m_item = *(_swigval),_swigval) -static PyObject *_wrap_wxListEvent_m_item_set(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject * _resultobj; - wxListItem * _result; - wxListEvent * _arg0; - wxListItem * _arg1; - PyObject * _argo0 = 0; - PyObject * _argo1 = 0; - char *_kwnames[] = { "self","m_item", NULL }; - - self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxListEvent_m_item_set",_kwnames,&_argo0,&_argo1)) - return NULL; - if (_argo0) { - if (_argo0 == Py_None) { _arg0 = NULL; } - else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxListEvent_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListEvent_m_item_set. Expected _wxListEvent_p."); - return NULL; - } - } - if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxListItem_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxListEvent_m_item_set. Expected _wxListItem_p."); - return NULL; - } - } -{ - PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxListItem *)wxListEvent_m_item_set(_arg0,_arg1); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) return NULL; -}{ _resultobj = wxPyMake_wxObject(_result); } - return _resultobj; -} - #define wxListEvent_m_item_get(_swigobj) (&_swigobj->m_item) static PyObject *_wrap_wxListEvent_m_item_get(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -2529,7 +2294,7 @@ static PyObject *_wrap_wxListEvent_m_item_get(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxListItem *)wxListEvent_m_item_get(_arg0); + _result = (wxListItem *)wxListEvent_m_item_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2537,8 +2302,8 @@ static PyObject *_wrap_wxListEvent_m_item_get(PyObject *self, PyObject *args, Py return _resultobj; } -#define wxListEvent_GetCode(_swigobj) (_swigobj->GetCode()) -static PyObject *_wrap_wxListEvent_GetCode(PyObject *self, PyObject *args, PyObject *kwargs) { +#define wxListEvent_GetKeyCode(_swigobj) (_swigobj->GetKeyCode()) +static PyObject *_wrap_wxListEvent_GetKeyCode(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; int _result; wxListEvent * _arg0; @@ -2546,18 +2311,18 @@ static PyObject *_wrap_wxListEvent_GetCode(PyObject *self, PyObject *args, PyObj char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxListEvent_GetCode",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxListEvent_GetKeyCode",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxListEvent_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListEvent_GetCode. Expected _wxListEvent_p."); + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListEvent_GetKeyCode. Expected _wxListEvent_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListEvent_GetCode(_arg0); + _result = (int )wxListEvent_GetKeyCode(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2585,7 +2350,7 @@ static PyObject *_wrap_wxListEvent_GetIndex(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListEvent_GetIndex(_arg0); + _result = (long )wxListEvent_GetIndex(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2613,7 +2378,7 @@ static PyObject *_wrap_wxListEvent_GetColumn(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListEvent_GetColumn(_arg0); + _result = (int )wxListEvent_GetColumn(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2642,7 +2407,7 @@ static PyObject *_wrap_wxListEvent_GetPoint(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxPoint (wxListEvent_GetPoint(_arg0)); + _result = new wxPoint (wxListEvent_GetPoint(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2671,13 +2436,17 @@ static PyObject *_wrap_wxListEvent_GetLabel(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - const wxString & _result_ref = wxListEvent_GetLabel(_arg0); + const wxString & _result_ref = wxListEvent_GetLabel(_arg0); _result = (wxString *) &_result_ref; wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } return _resultobj; } @@ -2702,13 +2471,17 @@ static PyObject *_wrap_wxListEvent_GetText(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - const wxString & _result_ref = wxListEvent_GetText(_arg0); + const wxString & _result_ref = wxListEvent_GetText(_arg0); _result = (wxString *) &_result_ref; wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } return _resultobj; } @@ -2733,7 +2506,7 @@ static PyObject *_wrap_wxListEvent_GetImage(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListEvent_GetImage(_arg0); + _result = (int )wxListEvent_GetImage(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2761,7 +2534,7 @@ static PyObject *_wrap_wxListEvent_GetData(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListEvent_GetData(_arg0); + _result = (long )wxListEvent_GetData(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2789,7 +2562,7 @@ static PyObject *_wrap_wxListEvent_GetMask(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListEvent_GetMask(_arg0); + _result = (long )wxListEvent_GetMask(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2817,7 +2590,7 @@ static PyObject *_wrap_wxListEvent_GetItem(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - const wxListItem & _result_ref = wxListEvent_GetItem(_arg0); + const wxListItem & _result_ref = wxListEvent_GetItem(_arg0); _result = (wxListItem *) &_result_ref; wxPyEndAllowThreads(__tstate); @@ -2846,7 +2619,7 @@ static PyObject *_wrap_wxListEvent_GetCacheFrom(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListEvent_GetCacheFrom(_arg0); + _result = (long )wxListEvent_GetCacheFrom(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2874,7 +2647,7 @@ static PyObject *_wrap_wxListEvent_GetCacheTo(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListEvent_GetCacheTo(_arg0); + _result = (long )wxListEvent_GetCacheTo(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2924,18 +2697,19 @@ static PyObject *_wrap_new_wxListCtrl(PyObject *self, PyObject *args, PyObject * wxSize * _arg3 = (wxSize *) &wxDefaultSize; long _arg4 = (long ) (wxLC_ICON); wxValidator * _arg5 = (wxValidator *) &wxDefaultValidator; - char * _arg6 = (char *) "listCtrl"; + wxString * _arg6 = (wxString *) &wxPyListCtrlNameStr; PyObject * _argo0 = 0; wxPoint temp; PyObject * _obj2 = 0; wxSize temp0; PyObject * _obj3 = 0; PyObject * _argo5 = 0; + PyObject * _obj6 = 0; char *_kwnames[] = { "parent","id","pos","size","style","validator","name", NULL }; char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|iOOlOs:new_wxListCtrl",_kwnames,&_argo0,&_arg1,&_obj2,&_obj3,&_arg4,&_argo5,&_arg6)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|iOOlOO:new_wxListCtrl",_kwnames,&_argo0,&_arg1,&_obj2,&_obj3,&_arg4,&_argo5,&_obj6)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2957,15 +2731,20 @@ static PyObject *_wrap_new_wxListCtrl(PyObject *self, PyObject *args, PyObject * return NULL; } if (_argo5) { - if (_argo5 == Py_None) { _arg5 = NULL; } - else if (SWIG_GetPtrObj(_argo5,(void **) &_arg5,"_wxValidator_p")) { + if (SWIG_GetPtrObj(_argo5,(void **) &_arg5,"_wxValidator_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 6 of new_wxListCtrl. Expected _wxValidator_p."); return NULL; } } + if (_obj6) +{ + _arg6 = wxString_in_helper(_obj6); + if (_arg6 == NULL) + return NULL; +} { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxPyListCtrl *)new_wxListCtrl(_arg0,_arg1,*_arg2,*_arg3,_arg4,*_arg5,_arg6); + _result = (wxPyListCtrl *)new_wxListCtrl(_arg0,_arg1,*_arg2,*_arg3,_arg4,*_arg5,*_arg6); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -2976,6 +2755,10 @@ static PyObject *_wrap_new_wxListCtrl(PyObject *self, PyObject *args, PyObject * Py_INCREF(Py_None); _resultobj = Py_None; } +{ + if (_obj6) + delete _arg6; +} return _resultobj; } @@ -2991,7 +2774,7 @@ static PyObject *_wrap_new_wxPreListCtrl(PyObject *self, PyObject *args, PyObjec return NULL; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxPyListCtrl *)new_wxPreListCtrl(); + _result = (wxPyListCtrl *)new_wxPreListCtrl(); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3016,7 +2799,7 @@ static PyObject *_wrap_wxListCtrl_Create(PyObject *self, PyObject *args, PyObjec wxSize * _arg4 = (wxSize *) &wxDefaultSize; long _arg5 = (long ) (wxLC_ICON); wxValidator * _arg6 = (wxValidator *) &wxDefaultValidator; - char * _arg7 = (char *) "listCtrl"; + wxString * _arg7 = (wxString *) &wxPyListCtrlNameStr; PyObject * _argo0 = 0; PyObject * _argo1 = 0; wxPoint temp; @@ -3024,10 +2807,11 @@ static PyObject *_wrap_wxListCtrl_Create(PyObject *self, PyObject *args, PyObjec wxSize temp0; PyObject * _obj4 = 0; PyObject * _argo6 = 0; + PyObject * _obj7 = 0; char *_kwnames[] = { "self","parent","id","pos","size","style","validator","name", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO|iOOlOs:wxListCtrl_Create",_kwnames,&_argo0,&_argo1,&_arg2,&_obj3,&_obj4,&_arg5,&_argo6,&_arg7)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO|iOOlOO:wxListCtrl_Create",_kwnames,&_argo0,&_argo1,&_arg2,&_obj3,&_obj4,&_arg5,&_argo6,&_obj7)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -3056,19 +2840,28 @@ static PyObject *_wrap_wxListCtrl_Create(PyObject *self, PyObject *args, PyObjec return NULL; } if (_argo6) { - if (_argo6 == Py_None) { _arg6 = NULL; } - else if (SWIG_GetPtrObj(_argo6,(void **) &_arg6,"_wxValidator_p")) { + if (SWIG_GetPtrObj(_argo6,(void **) &_arg6,"_wxValidator_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 7 of wxListCtrl_Create. Expected _wxValidator_p."); return NULL; } } + if (_obj7) +{ + _arg7 = wxString_in_helper(_obj7); + if (_arg7 == NULL) + return NULL; +} { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_Create(_arg0,_arg1,_arg2,*_arg3,*_arg4,_arg5,*_arg6,_arg7); + _result = (bool )wxListCtrl_Create(_arg0,_arg1,_arg2,*_arg3,*_arg4,_arg5,*_arg6,*_arg7); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; } _resultobj = Py_BuildValue("i",_result); +{ + if (_obj7) + delete _arg7; +} return _resultobj; } @@ -3101,7 +2894,7 @@ static PyObject *_wrap_wxListCtrl__setCallbackInfo(PyObject *self, PyObject *arg } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListCtrl__setCallbackInfo(_arg0,_arg1,_arg2); + wxListCtrl__setCallbackInfo(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3138,7 +2931,7 @@ static PyObject *_wrap_wxListCtrl_SetForegroundColour(PyObject *self, PyObject * } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_SetForegroundColour(_arg0,*_arg1); + _result = (bool )wxListCtrl_SetForegroundColour(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3174,7 +2967,7 @@ static PyObject *_wrap_wxListCtrl_SetBackgroundColour(PyObject *self, PyObject * } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_SetBackgroundColour(_arg0,*_arg1); + _result = (bool )wxListCtrl_SetBackgroundColour(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3184,6 +2977,7 @@ static PyObject *_wrap_wxListCtrl_SetBackgroundColour(PyObject *self, PyObject * static wxListItem * wxPyListCtrl_GetColumn(wxPyListCtrl *self,int col) { wxListItem item; + item.SetMask(0xFFFF); if (self->GetColumn(col, item)) return new wxListItem(item); else @@ -3209,7 +3003,7 @@ static PyObject *_wrap_wxListCtrl_GetColumn(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxListItem *)wxPyListCtrl_GetColumn(_arg0,_arg1); + _result = (wxListItem *)wxPyListCtrl_GetColumn(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3239,15 +3033,14 @@ static PyObject *_wrap_wxListCtrl_SetColumn(PyObject *self, PyObject *args, PyOb } } if (_argo2) { - if (_argo2 == Py_None) { _arg2 = NULL; } - else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxListItem_p")) { + if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxListItem_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of wxListCtrl_SetColumn. Expected _wxListItem_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_SetColumn(_arg0,_arg1,*_arg2); + _result = (bool )wxListCtrl_SetColumn(_arg0,_arg1,*_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3276,7 +3069,7 @@ static PyObject *_wrap_wxListCtrl_GetColumnWidth(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListCtrl_GetColumnWidth(_arg0,_arg1); + _result = (int )wxListCtrl_GetColumnWidth(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3306,7 +3099,7 @@ static PyObject *_wrap_wxListCtrl_SetColumnWidth(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_SetColumnWidth(_arg0,_arg1,_arg2); + _result = (bool )wxListCtrl_SetColumnWidth(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3334,7 +3127,7 @@ static PyObject *_wrap_wxListCtrl_GetCountPerPage(PyObject *self, PyObject *args } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListCtrl_GetCountPerPage(_arg0); + _result = (int )wxListCtrl_GetCountPerPage(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3362,7 +3155,7 @@ static PyObject *_wrap_wxListCtrl_GetEditControl(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxTextCtrl *)wxListCtrl_GetEditControl(_arg0); + _result = (wxTextCtrl *)wxListCtrl_GetEditControl(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3399,7 +3192,7 @@ static PyObject *_wrap_wxListCtrl_GetItem(PyObject *self, PyObject *args, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxListItem *)wxPyListCtrl_GetItem(_arg0,_arg1,_arg2); + _result = (wxListItem *)wxPyListCtrl_GetItem(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3428,15 +3221,14 @@ static PyObject *_wrap_wxListCtrl_SetItem(PyObject *self, PyObject *args, PyObje } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxListItem_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxListItem_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxListCtrl_SetItem. Expected _wxListItem_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_SetItem(_arg0,*_arg1); + _result = (bool )wxListCtrl_SetItem(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3468,26 +3260,13 @@ static PyObject *_wrap_wxListCtrl_SetStringItem(PyObject *self, PyObject *args, } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj3) && !PyUnicode_Check(_obj3)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj3, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg3 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj3)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg3 = wxString_in_helper(_obj3); + if (_arg3 == NULL) return NULL; - } - _arg3 = new wxString(PyString_AS_STRING(_obj3), PyString_GET_SIZE(_obj3)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListCtrl_SetStringItem(_arg0,_arg1,_arg2,*_arg3,_arg4); + _result = (long )wxListCtrl_SetStringItem(_arg0,_arg1,_arg2,*_arg3,_arg4); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3521,7 +3300,7 @@ static PyObject *_wrap_wxListCtrl_GetItemState(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListCtrl_GetItemState(_arg0,_arg1,_arg2); + _result = (int )wxListCtrl_GetItemState(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3552,7 +3331,7 @@ static PyObject *_wrap_wxListCtrl_SetItemState(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_SetItemState(_arg0,_arg1,_arg2,_arg3); + _result = (bool )wxListCtrl_SetItemState(_arg0,_arg1,_arg2,_arg3); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3583,7 +3362,7 @@ static PyObject *_wrap_wxListCtrl_SetItemImage(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_SetItemImage(_arg0,_arg1,_arg2,_arg3); + _result = (bool )wxListCtrl_SetItemImage(_arg0,_arg1,_arg2,_arg3); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3612,12 +3391,16 @@ static PyObject *_wrap_wxListCtrl_GetItemText(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxString (wxListCtrl_GetItemText(_arg0,_arg1)); + _result = new wxString (wxListCtrl_GetItemText(_arg0,_arg1)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } { delete _result; @@ -3646,26 +3429,13 @@ static PyObject *_wrap_wxListCtrl_SetItemText(PyObject *self, PyObject *args, Py } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj2) && !PyUnicode_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj2, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg2 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg2 = wxString_in_helper(_obj2); + if (_arg2 == NULL) return NULL; - } - _arg2 = new wxString(PyString_AS_STRING(_obj2), PyString_GET_SIZE(_obj2)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListCtrl_SetItemText(_arg0,_arg1,*_arg2); + wxListCtrl_SetItemText(_arg0,_arg1,*_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3699,7 +3469,7 @@ static PyObject *_wrap_wxListCtrl_GetItemData(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListCtrl_GetItemData(_arg0,_arg1); + _result = (long )wxListCtrl_GetItemData(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3729,7 +3499,7 @@ static PyObject *_wrap_wxListCtrl_SetItemData(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_SetItemData(_arg0,_arg1,_arg2); + _result = (bool )wxListCtrl_SetItemData(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3763,7 +3533,7 @@ static PyObject *_wrap_wxListCtrl_GetItemPosition(PyObject *self, PyObject *args } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxPoint *)wxPyListCtrl_GetItemPosition(_arg0,_arg1); + _result = (wxPoint *)wxPyListCtrl_GetItemPosition(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3804,7 +3574,7 @@ static PyObject *_wrap_wxListCtrl_GetItemRect(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxRect *)wxPyListCtrl_GetItemRect(_arg0,_arg1,_arg2); + _result = (wxRect *)wxPyListCtrl_GetItemRect(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3847,7 +3617,7 @@ static PyObject *_wrap_wxListCtrl_SetItemPosition(PyObject *self, PyObject *args } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_SetItemPosition(_arg0,_arg1,*_arg2); + _result = (bool )wxListCtrl_SetItemPosition(_arg0,_arg1,*_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3875,7 +3645,7 @@ static PyObject *_wrap_wxListCtrl_GetItemCount(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListCtrl_GetItemCount(_arg0); + _result = (int )wxListCtrl_GetItemCount(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3903,7 +3673,7 @@ static PyObject *_wrap_wxListCtrl_GetColumnCount(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListCtrl_GetColumnCount(_arg0); + _result = (int )wxListCtrl_GetColumnCount(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3934,7 +3704,7 @@ static PyObject *_wrap_wxListCtrl_GetItemSpacing(PyObject *self, PyObject *args, _arg1 = (bool ) tempbool1; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListCtrl_GetItemSpacing(_arg0,_arg1); + _result = (int )wxListCtrl_GetItemSpacing(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3962,7 +3732,7 @@ static PyObject *_wrap_wxListCtrl_GetSelectedItemCount(PyObject *self, PyObject } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListCtrl_GetSelectedItemCount(_arg0); + _result = (int )wxListCtrl_GetSelectedItemCount(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -3991,7 +3761,7 @@ static PyObject *_wrap_wxListCtrl_GetTextColour(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxColour (wxListCtrl_GetTextColour(_arg0)); + _result = new wxColour (wxListCtrl_GetTextColour(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4027,7 +3797,7 @@ static PyObject *_wrap_wxListCtrl_SetTextColour(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListCtrl_SetTextColour(_arg0,*_arg1); + wxListCtrl_SetTextColour(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4056,7 +3826,7 @@ static PyObject *_wrap_wxListCtrl_GetTopItem(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListCtrl_GetTopItem(_arg0); + _result = (long )wxListCtrl_GetTopItem(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4087,7 +3857,7 @@ static PyObject *_wrap_wxListCtrl_SetSingleStyle(PyObject *self, PyObject *args, _arg2 = (bool ) tempbool2; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListCtrl_SetSingleStyle(_arg0,_arg1,_arg2); + wxListCtrl_SetSingleStyle(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4116,7 +3886,7 @@ static PyObject *_wrap_wxListCtrl_SetWindowStyleFlag(PyObject *self, PyObject *a } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListCtrl_SetWindowStyleFlag(_arg0,_arg1); + wxListCtrl_SetWindowStyleFlag(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4148,7 +3918,7 @@ static PyObject *_wrap_wxListCtrl_GetNextItem(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListCtrl_GetNextItem(_arg0,_arg1,_arg2,_arg3); + _result = (long )wxListCtrl_GetNextItem(_arg0,_arg1,_arg2,_arg3); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4177,7 +3947,7 @@ static PyObject *_wrap_wxListCtrl_GetImageList(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxImageList *)wxListCtrl_GetImageList(_arg0,_arg1); + _result = (wxImageList *)wxListCtrl_GetImageList(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4214,7 +3984,7 @@ static PyObject *_wrap_wxListCtrl_SetImageList(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListCtrl_SetImageList(_arg0,_arg1,_arg2); + wxListCtrl_SetImageList(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4252,7 +4022,7 @@ static PyObject *_wrap_wxListCtrl_AssignImageList(PyObject *self, PyObject *args } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListCtrl_AssignImageList(_arg0,_arg1,_arg2); + wxListCtrl_AssignImageList(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4281,7 +4051,7 @@ static PyObject *_wrap_wxListCtrl_IsVirtual(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_IsVirtual(_arg0); + _result = (bool )wxListCtrl_IsVirtual(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4309,7 +4079,7 @@ static PyObject *_wrap_wxListCtrl_RefreshItem(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListCtrl_RefreshItem(_arg0,_arg1); + wxListCtrl_RefreshItem(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4339,7 +4109,7 @@ static PyObject *_wrap_wxListCtrl_RefreshItems(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListCtrl_RefreshItems(_arg0,_arg1,_arg2); + wxListCtrl_RefreshItems(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4369,7 +4139,7 @@ static PyObject *_wrap_wxListCtrl_Arrange(PyObject *self, PyObject *args, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_Arrange(_arg0,_arg1); + _result = (bool )wxListCtrl_Arrange(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4398,7 +4168,7 @@ static PyObject *_wrap_wxListCtrl_DeleteItem(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_DeleteItem(_arg0,_arg1); + _result = (bool )wxListCtrl_DeleteItem(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4426,7 +4196,7 @@ static PyObject *_wrap_wxListCtrl_DeleteAllItems(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_DeleteAllItems(_arg0); + _result = (bool )wxListCtrl_DeleteAllItems(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4455,7 +4225,7 @@ static PyObject *_wrap_wxListCtrl_DeleteColumn(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_DeleteColumn(_arg0,_arg1); + _result = (bool )wxListCtrl_DeleteColumn(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4483,7 +4253,7 @@ static PyObject *_wrap_wxListCtrl_DeleteAllColumns(PyObject *self, PyObject *arg } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_DeleteAllColumns(_arg0); + _result = (bool )wxListCtrl_DeleteAllColumns(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4510,7 +4280,7 @@ static PyObject *_wrap_wxListCtrl_ClearAll(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListCtrl_ClearAll(_arg0); + wxListCtrl_ClearAll(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4540,7 +4310,7 @@ static PyObject *_wrap_wxListCtrl_EditLabel(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxTextCtrl *)wxListCtrl_EditLabel(_arg0,_arg1); + _result = (wxTextCtrl *)wxListCtrl_EditLabel(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4571,7 +4341,7 @@ static PyObject *_wrap_wxListCtrl_EndEditLabel(PyObject *self, PyObject *args, P _arg1 = (bool ) tempbool1; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_EndEditLabel(_arg0,_arg1); + _result = (bool )wxListCtrl_EndEditLabel(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4600,7 +4370,7 @@ static PyObject *_wrap_wxListCtrl_EnsureVisible(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_EnsureVisible(_arg0,_arg1); + _result = (bool )wxListCtrl_EnsureVisible(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4632,27 +4402,14 @@ static PyObject *_wrap_wxListCtrl_FindItem(PyObject *self, PyObject *args, PyObj } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj2) && !PyUnicode_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj2, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg2 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg2 = wxString_in_helper(_obj2); + if (_arg2 == NULL) return NULL; - } - _arg2 = new wxString(PyString_AS_STRING(_obj2), PyString_GET_SIZE(_obj2)); -#endif } _arg3 = (bool ) tempbool3; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListCtrl_FindItem(_arg0,_arg1,*_arg2,_arg3); + _result = (long )wxListCtrl_FindItem(_arg0,_arg1,*_arg2,_arg3); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4686,7 +4443,7 @@ static PyObject *_wrap_wxListCtrl_FindItemData(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListCtrl_FindItemData(_arg0,_arg1,_arg2); + _result = (long )wxListCtrl_FindItemData(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4724,7 +4481,7 @@ static PyObject *_wrap_wxListCtrl_FindItemAtPos(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListCtrl_FindItemAtPos(_arg0,_arg1,*_arg2,_arg3); + _result = (long )wxListCtrl_FindItemAtPos(_arg0,_arg1,*_arg2,_arg3); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4765,7 +4522,7 @@ static PyObject *_wrap_wxListCtrl_HitTest(PyObject *self, PyObject *args, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListCtrl_HitTest(_arg0,*_arg1,*_arg2); + _result = (long )wxListCtrl_HitTest(_arg0,*_arg1,*_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4799,15 +4556,14 @@ static PyObject *_wrap_wxListCtrl_InsertItem(PyObject *self, PyObject *args, PyO } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxListItem_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxListItem_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxListCtrl_InsertItem. Expected _wxListItem_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListCtrl_InsertItem(_arg0,*_arg1); + _result = (long )wxListCtrl_InsertItem(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4837,26 +4593,13 @@ static PyObject *_wrap_wxListCtrl_InsertStringItem(PyObject *self, PyObject *arg } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj2) && !PyUnicode_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj2, &tmpPtr, &tmpSize) == -1) + _arg2 = wxString_in_helper(_obj2); + if (_arg2 == NULL) return NULL; - _arg2 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - _arg2 = new wxString(PyString_AS_STRING(_obj2), PyString_GET_SIZE(_obj2)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListCtrl_InsertStringItem(_arg0,_arg1,*_arg2); + _result = (long )wxListCtrl_InsertStringItem(_arg0,_arg1,*_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4890,7 +4633,7 @@ static PyObject *_wrap_wxListCtrl_InsertImageItem(PyObject *self, PyObject *args } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListCtrl_InsertImageItem(_arg0,_arg1,_arg2); + _result = (long )wxListCtrl_InsertImageItem(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4921,26 +4664,13 @@ static PyObject *_wrap_wxListCtrl_InsertImageStringItem(PyObject *self, PyObject } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj2) && !PyUnicode_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj2, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg2 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg2 = wxString_in_helper(_obj2); + if (_arg2 == NULL) return NULL; - } - _arg2 = new wxString(PyString_AS_STRING(_obj2), PyString_GET_SIZE(_obj2)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListCtrl_InsertImageStringItem(_arg0,_arg1,*_arg2,_arg3); + _result = (long )wxListCtrl_InsertImageStringItem(_arg0,_arg1,*_arg2,_arg3); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -4974,15 +4704,14 @@ static PyObject *_wrap_wxListCtrl_InsertColumnInfo(PyObject *self, PyObject *arg } } if (_argo2) { - if (_argo2 == Py_None) { _arg2 = NULL; } - else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxListItem_p")) { + if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxListItem_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of wxListCtrl_InsertColumnInfo. Expected _wxListItem_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListCtrl_InsertColumnInfo(_arg0,_arg1,*_arg2); + _result = (long )wxListCtrl_InsertColumnInfo(_arg0,_arg1,*_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5014,26 +4743,13 @@ static PyObject *_wrap_wxListCtrl_InsertColumn(PyObject *self, PyObject *args, P } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj2) && !PyUnicode_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg2 = wxString_in_helper(_obj2); + if (_arg2 == NULL) return NULL; - } - if (PyString_AsStringAndSize(_obj2, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg2 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - _arg2 = new wxString(PyString_AS_STRING(_obj2), PyString_GET_SIZE(_obj2)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListCtrl_InsertColumn(_arg0,_arg1,*_arg2,_arg3,_arg4); + _result = (long )wxListCtrl_InsertColumn(_arg0,_arg1,*_arg2,_arg3,_arg4); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5065,7 +4781,7 @@ static PyObject *_wrap_wxListCtrl_SetItemCount(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListCtrl_SetItemCount(_arg0,_arg1); + wxListCtrl_SetItemCount(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5096,7 +4812,7 @@ static PyObject *_wrap_wxListCtrl_ScrollList(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListCtrl_ScrollList(_arg0,_arg1,_arg2); + _result = (bool )wxListCtrl_ScrollList(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5104,6 +4820,142 @@ static PyObject *_wrap_wxListCtrl_ScrollList(PyObject *self, PyObject *args, PyO return _resultobj; } +#define wxListCtrl_SetItemTextColour(_swigobj,_swigarg0,_swigarg1) (_swigobj->SetItemTextColour(_swigarg0,_swigarg1)) +static PyObject *_wrap_wxListCtrl_SetItemTextColour(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxPyListCtrl * _arg0; + long _arg1; + wxColour * _arg2; + PyObject * _argo0 = 0; + wxColour temp; + PyObject * _obj2 = 0; + char *_kwnames[] = { "self","item","col", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OlO:wxListCtrl_SetItemTextColour",_kwnames,&_argo0,&_arg1,&_obj2)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyListCtrl_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListCtrl_SetItemTextColour. Expected _wxPyListCtrl_p."); + return NULL; + } + } +{ + _arg2 = &temp; + if (! wxColour_helper(_obj2, &_arg2)) + return NULL; +} +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxListCtrl_SetItemTextColour(_arg0,_arg1,*_arg2); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; + return _resultobj; +} + +#define wxListCtrl_GetItemTextColour(_swigobj,_swigarg0) (_swigobj->GetItemTextColour(_swigarg0)) +static PyObject *_wrap_wxListCtrl_GetItemTextColour(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxColour * _result; + wxPyListCtrl * _arg0; + long _arg1; + PyObject * _argo0 = 0; + char *_kwnames[] = { "self","item", NULL }; + char _ptemp[128]; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Ol:wxListCtrl_GetItemTextColour",_kwnames,&_argo0,&_arg1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyListCtrl_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListCtrl_GetItemTextColour. Expected _wxPyListCtrl_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = new wxColour (wxListCtrl_GetItemTextColour(_arg0,_arg1)); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} SWIG_MakePtr(_ptemp, (void *) _result,"_wxColour_p"); + _resultobj = Py_BuildValue("s",_ptemp); + return _resultobj; +} + +#define wxListCtrl_SetItemBackgroundColour(_swigobj,_swigarg0,_swigarg1) (_swigobj->SetItemBackgroundColour(_swigarg0,_swigarg1)) +static PyObject *_wrap_wxListCtrl_SetItemBackgroundColour(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxPyListCtrl * _arg0; + long _arg1; + wxColour * _arg2; + PyObject * _argo0 = 0; + wxColour temp; + PyObject * _obj2 = 0; + char *_kwnames[] = { "self","item","col", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OlO:wxListCtrl_SetItemBackgroundColour",_kwnames,&_argo0,&_arg1,&_obj2)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyListCtrl_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListCtrl_SetItemBackgroundColour. Expected _wxPyListCtrl_p."); + return NULL; + } + } +{ + _arg2 = &temp; + if (! wxColour_helper(_obj2, &_arg2)) + return NULL; +} +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxListCtrl_SetItemBackgroundColour(_arg0,_arg1,*_arg2); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; + return _resultobj; +} + +#define wxListCtrl_GetItemBackgroundColour(_swigobj,_swigarg0) (_swigobj->GetItemBackgroundColour(_swigarg0)) +static PyObject *_wrap_wxListCtrl_GetItemBackgroundColour(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxColour * _result; + wxPyListCtrl * _arg0; + long _arg1; + PyObject * _argo0 = 0; + char *_kwnames[] = { "self","item", NULL }; + char _ptemp[128]; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Ol:wxListCtrl_GetItemBackgroundColour",_kwnames,&_argo0,&_arg1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyListCtrl_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListCtrl_GetItemBackgroundColour. Expected _wxPyListCtrl_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = new wxColour (wxListCtrl_GetItemBackgroundColour(_arg0,_arg1)); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} SWIG_MakePtr(_ptemp, (void *) _result,"_wxColour_p"); + _resultobj = Py_BuildValue("s",_ptemp); + return _resultobj; +} + static bool wxPyListCtrl_SortItems(wxPyListCtrl *self,PyObject * func) { if (!PyCallable_Check(func)) return FALSE; @@ -5133,7 +4985,7 @@ static PyObject *_wrap_wxListCtrl_SortItems(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxPyListCtrl_SortItems(_arg0,_arg1); + _result = (bool )wxPyListCtrl_SortItems(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5141,6 +4993,40 @@ static PyObject *_wrap_wxListCtrl_SortItems(PyObject *self, PyObject *args, PyOb return _resultobj; } +static wxWindow * wxPyListCtrl_GetMainWindow(wxPyListCtrl *self) { + #ifdef __WXMSW__ + return self; + #else + return (wxWindow*)self->m_mainWin; + #endif + } +static PyObject *_wrap_wxListCtrl_GetMainWindow(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxWindow * _result; + wxPyListCtrl * _arg0; + PyObject * _argo0 = 0; + char *_kwnames[] = { "self", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxListCtrl_GetMainWindow",_kwnames,&_argo0)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyListCtrl_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListCtrl_GetMainWindow. Expected _wxPyListCtrl_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = (wxWindow *)wxPyListCtrl_GetMainWindow(_arg0); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +}{ _resultobj = wxPyMake_wxObject(_result); } + return _resultobj; +} + static void *SwigwxListViewTowxPyListCtrl(void *ptr) { wxListView *src; wxPyListCtrl *dest; @@ -5191,7 +5077,7 @@ static PyObject *_wrap_new_wxListView(PyObject *self, PyObject *args, PyObject * wxSize * _arg3 = (wxSize *) &wxDefaultSize; long _arg4 = (long ) (wxLC_REPORT); wxValidator * _arg5 = (wxValidator *) &wxDefaultValidator; - wxString * _arg6 = (wxString *) &"listctrl"; + wxString * _arg6 = (wxString *) &wxPyListCtrlNameStr; PyObject * _argo0 = 0; wxPoint temp; PyObject * _obj2 = 0; @@ -5225,34 +5111,20 @@ static PyObject *_wrap_new_wxListView(PyObject *self, PyObject *args, PyObject * return NULL; } if (_argo5) { - if (_argo5 == Py_None) { _arg5 = NULL; } - else if (SWIG_GetPtrObj(_argo5,(void **) &_arg5,"_wxValidator_p")) { + if (SWIG_GetPtrObj(_argo5,(void **) &_arg5,"_wxValidator_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 6 of new_wxListView. Expected _wxValidator_p."); return NULL; } } if (_obj6) { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj6) && !PyUnicode_Check(_obj6)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg6 = wxString_in_helper(_obj6); + if (_arg6 == NULL) return NULL; - } - if (PyString_AsStringAndSize(_obj6, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg6 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj6)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - _arg6 = new wxString(PyString_AS_STRING(_obj6), PyString_GET_SIZE(_obj6)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxListView *)new_wxListView(_arg0,_arg1,*_arg2,*_arg3,_arg4,*_arg5,*_arg6); + _result = (wxListView *)new_wxListView(_arg0,_arg1,*_arg2,*_arg3,_arg4,*_arg5,*_arg6); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5282,7 +5154,7 @@ static PyObject *_wrap_new_wxPreListView(PyObject *self, PyObject *args, PyObjec return NULL; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxListView *)new_wxPreListView(); + _result = (wxListView *)new_wxPreListView(); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5307,7 +5179,7 @@ static PyObject *_wrap_wxListView_Create(PyObject *self, PyObject *args, PyObjec wxSize * _arg4 = (wxSize *) &wxDefaultSize; long _arg5 = (long ) (wxLC_REPORT); wxValidator * _arg6 = (wxValidator *) &wxDefaultValidator; - wxString * _arg7 = (wxString *) &"listctrl"; + wxString * _arg7 = (wxString *) &wxPyListCtrlNameStr; PyObject * _argo0 = 0; PyObject * _argo1 = 0; wxPoint temp; @@ -5348,34 +5220,20 @@ static PyObject *_wrap_wxListView_Create(PyObject *self, PyObject *args, PyObjec return NULL; } if (_argo6) { - if (_argo6 == Py_None) { _arg6 = NULL; } - else if (SWIG_GetPtrObj(_argo6,(void **) &_arg6,"_wxValidator_p")) { + if (SWIG_GetPtrObj(_argo6,(void **) &_arg6,"_wxValidator_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 7 of wxListView_Create. Expected _wxValidator_p."); return NULL; } } if (_obj7) { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj7) && !PyUnicode_Check(_obj7)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg7 = wxString_in_helper(_obj7); + if (_arg7 == NULL) return NULL; - } - if (PyString_AsStringAndSize(_obj7, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg7 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj7)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - _arg7 = new wxString(PyString_AS_STRING(_obj7), PyString_GET_SIZE(_obj7)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListView_Create(_arg0,_arg1,_arg2,*_arg3,*_arg4,_arg5,*_arg6,*_arg7); + _result = (bool )wxListView_Create(_arg0,_arg1,_arg2,*_arg3,*_arg4,_arg5,*_arg6,*_arg7); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5410,7 +5268,7 @@ static PyObject *_wrap_wxListView_Select(PyObject *self, PyObject *args, PyObjec _arg2 = (bool ) tempbool2; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListView_Select(_arg0,_arg1,_arg2); + wxListView_Select(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5439,7 +5297,7 @@ static PyObject *_wrap_wxListView_Focus(PyObject *self, PyObject *args, PyObject } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListView_Focus(_arg0,_arg1); + wxListView_Focus(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5468,7 +5326,7 @@ static PyObject *_wrap_wxListView_GetFocusedItem(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListView_GetFocusedItem(_arg0); + _result = (long )wxListView_GetFocusedItem(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5497,7 +5355,7 @@ static PyObject *_wrap_wxListView_GetNextSelected(PyObject *self, PyObject *args } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListView_GetNextSelected(_arg0,_arg1); + _result = (long )wxListView_GetNextSelected(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5525,7 +5383,7 @@ static PyObject *_wrap_wxListView_GetFirstSelected(PyObject *self, PyObject *arg } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListView_GetFirstSelected(_arg0); + _result = (long )wxListView_GetFirstSelected(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5554,7 +5412,7 @@ static PyObject *_wrap_wxListView_IsSelected(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxListView_IsSelected(_arg0,_arg1); + _result = (bool )wxListView_IsSelected(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5583,7 +5441,7 @@ static PyObject *_wrap_wxListView_SetColumnImage(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListView_SetColumnImage(_arg0,_arg1,_arg2); + wxListView_SetColumnImage(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5612,7 +5470,7 @@ static PyObject *_wrap_wxListView_ClearColumnImage(PyObject *self, PyObject *arg } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxListView_ClearColumnImage(_arg0,_arg1); + wxListView_ClearColumnImage(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5652,15 +5510,14 @@ static PyObject *_wrap_new_wxTreeItemAttr(PyObject *self, PyObject *args, PyObje return NULL; } if (_argo2) { - if (_argo2 == Py_None) { _arg2 = NULL; } - else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxFont_p")) { + if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxFont_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of new_wxTreeItemAttr. Expected _wxFont_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxTreeItemAttr *)new_wxTreeItemAttr(*_arg0,*_arg1,*_arg2); + _result = (wxTreeItemAttr *)new_wxTreeItemAttr(*_arg0,*_arg1,*_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5701,7 +5558,7 @@ static PyObject *_wrap_wxTreeItemAttr_SetTextColour(PyObject *self, PyObject *ar } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeItemAttr_SetTextColour(_arg0,*_arg1); + wxTreeItemAttr_SetTextColour(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5737,7 +5594,7 @@ static PyObject *_wrap_wxTreeItemAttr_SetBackgroundColour(PyObject *self, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeItemAttr_SetBackgroundColour(_arg0,*_arg1); + wxTreeItemAttr_SetBackgroundColour(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5766,15 +5623,14 @@ static PyObject *_wrap_wxTreeItemAttr_SetFont(PyObject *self, PyObject *args, Py } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxFont_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxFont_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeItemAttr_SetFont. Expected _wxFont_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeItemAttr_SetFont(_arg0,*_arg1); + wxTreeItemAttr_SetFont(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5803,7 +5659,7 @@ static PyObject *_wrap_wxTreeItemAttr_HasTextColour(PyObject *self, PyObject *ar } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxTreeItemAttr_HasTextColour(_arg0); + _result = (bool )wxTreeItemAttr_HasTextColour(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5831,7 +5687,7 @@ static PyObject *_wrap_wxTreeItemAttr_HasBackgroundColour(PyObject *self, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxTreeItemAttr_HasBackgroundColour(_arg0); + _result = (bool )wxTreeItemAttr_HasBackgroundColour(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5859,7 +5715,7 @@ static PyObject *_wrap_wxTreeItemAttr_HasFont(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxTreeItemAttr_HasFont(_arg0); + _result = (bool )wxTreeItemAttr_HasFont(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5888,7 +5744,7 @@ static PyObject *_wrap_wxTreeItemAttr_GetTextColour(PyObject *self, PyObject *ar } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxColour (wxTreeItemAttr_GetTextColour(_arg0)); + _result = new wxColour (wxTreeItemAttr_GetTextColour(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5918,7 +5774,7 @@ static PyObject *_wrap_wxTreeItemAttr_GetBackgroundColour(PyObject *self, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxColour (wxTreeItemAttr_GetBackgroundColour(_arg0)); + _result = new wxColour (wxTreeItemAttr_GetBackgroundColour(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5948,7 +5804,7 @@ static PyObject *_wrap_wxTreeItemAttr_GetFont(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxFont (wxTreeItemAttr_GetFont(_arg0)); + _result = new wxFont (wxTreeItemAttr_GetFont(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -5969,7 +5825,7 @@ static PyObject *_wrap_new_wxTreeItemId(PyObject *self, PyObject *args, PyObject return NULL; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxTreeItemId *)new_wxTreeItemId(); + _result = (wxTreeItemId *)new_wxTreeItemId(); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6002,7 +5858,7 @@ static PyObject *_wrap_delete_wxTreeItemId(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - delete_wxTreeItemId(_arg0); + delete_wxTreeItemId(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6031,7 +5887,7 @@ static PyObject *_wrap_wxTreeItemId_IsOk(PyObject *self, PyObject *args, PyObjec } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxTreeItemId_IsOk(_arg0); + _result = (bool )wxTreeItemId_IsOk(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6071,7 +5927,7 @@ static PyObject *_wrap_wxTreeItemId___cmp__(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxTreeItemId___cmp__(_arg0,_arg1); + _result = (int )wxTreeItemId___cmp__(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6079,14 +5935,6 @@ static PyObject *_wrap_wxTreeItemId___cmp__(PyObject *self, PyObject *args, PyOb return _resultobj; } -static void *SwigwxPyTreeItemDataTowxObject(void *ptr) { - wxPyTreeItemData *src; - wxObject *dest; - src = (wxPyTreeItemData *) ptr; - dest = (wxObject *) src; - return (void *) dest; -} - #define new_wxTreeItemData(_swigarg0) (new wxPyTreeItemData(_swigarg0)) static PyObject *_wrap_new_wxTreeItemData(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -6105,7 +5953,7 @@ static PyObject *_wrap_new_wxTreeItemData(PyObject *self, PyObject *args, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxPyTreeItemData *)new_wxTreeItemData(_arg0); + _result = (wxPyTreeItemData *)new_wxTreeItemData(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6139,7 +5987,7 @@ static PyObject *_wrap_wxTreeItemData_GetData(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (PyObject *)wxTreeItemData_GetData(_arg0); + _result = (PyObject *)wxTreeItemData_GetData(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6173,7 +6021,7 @@ static PyObject *_wrap_wxTreeItemData_SetData(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeItemData_SetData(_arg0,_arg1); + wxTreeItemData_SetData(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6203,7 +6051,7 @@ static PyObject *_wrap_wxTreeItemData_GetId(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - const wxTreeItemId & _result_ref = wxTreeItemData_GetId(_arg0); + const wxTreeItemId & _result_ref = wxTreeItemData_GetId(_arg0); _result = (wxTreeItemId *) &_result_ref; wxPyEndAllowThreads(__tstate); @@ -6238,15 +6086,14 @@ static PyObject *_wrap_wxTreeItemData_SetId(PyObject *self, PyObject *args, PyOb } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeItemData_SetId. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeItemData_SetId(_arg0,*_arg1); + wxTreeItemData_SetId(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6301,7 +6148,7 @@ static PyObject *_wrap_new_wxTreeEvent(PyObject *self, PyObject *args, PyObject return NULL; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxTreeEvent *)new_wxTreeEvent(_arg0,_arg1); + _result = (wxTreeEvent *)new_wxTreeEvent(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6336,7 +6183,7 @@ static PyObject *_wrap_wxTreeEvent_GetItem(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeEvent_GetItem(_arg0)); + _result = new wxTreeItemId (wxTreeEvent_GetItem(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6345,6 +6192,42 @@ static PyObject *_wrap_wxTreeEvent_GetItem(PyObject *self, PyObject *args, PyObj return _resultobj; } +#define wxTreeEvent_SetItem(_swigobj,_swigarg0) (_swigobj->SetItem(_swigarg0)) +static PyObject *_wrap_wxTreeEvent_SetItem(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxTreeEvent * _arg0; + wxTreeItemId * _arg1; + PyObject * _argo0 = 0; + PyObject * _argo1 = 0; + char *_kwnames[] = { "self","item", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTreeEvent_SetItem",_kwnames,&_argo0,&_argo1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxTreeEvent_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeEvent_SetItem. Expected _wxTreeEvent_p."); + return NULL; + } + } + if (_argo1) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeEvent_SetItem. Expected _wxTreeItemId_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxTreeEvent_SetItem(_arg0,*_arg1); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; + return _resultobj; +} + #define wxTreeEvent_GetOldItem(_swigobj) (_swigobj->GetOldItem()) static PyObject *_wrap_wxTreeEvent_GetOldItem(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -6366,7 +6249,7 @@ static PyObject *_wrap_wxTreeEvent_GetOldItem(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeEvent_GetOldItem(_arg0)); + _result = new wxTreeItemId (wxTreeEvent_GetOldItem(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6375,6 +6258,42 @@ static PyObject *_wrap_wxTreeEvent_GetOldItem(PyObject *self, PyObject *args, Py return _resultobj; } +#define wxTreeEvent_SetOldItem(_swigobj,_swigarg0) (_swigobj->SetOldItem(_swigarg0)) +static PyObject *_wrap_wxTreeEvent_SetOldItem(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxTreeEvent * _arg0; + wxTreeItemId * _arg1; + PyObject * _argo0 = 0; + PyObject * _argo1 = 0; + char *_kwnames[] = { "self","item", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTreeEvent_SetOldItem",_kwnames,&_argo0,&_argo1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxTreeEvent_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeEvent_SetOldItem. Expected _wxTreeEvent_p."); + return NULL; + } + } + if (_argo1) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeEvent_SetOldItem. Expected _wxTreeItemId_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxTreeEvent_SetOldItem(_arg0,*_arg1); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; + return _resultobj; +} + #define wxTreeEvent_GetPoint(_swigobj) (_swigobj->GetPoint()) static PyObject *_wrap_wxTreeEvent_GetPoint(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -6396,7 +6315,7 @@ static PyObject *_wrap_wxTreeEvent_GetPoint(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxPoint (wxTreeEvent_GetPoint(_arg0)); + _result = new wxPoint (wxTreeEvent_GetPoint(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6405,6 +6324,42 @@ static PyObject *_wrap_wxTreeEvent_GetPoint(PyObject *self, PyObject *args, PyOb return _resultobj; } +#define wxTreeEvent_SetPoint(_swigobj,_swigarg0) (_swigobj->SetPoint(_swigarg0)) +static PyObject *_wrap_wxTreeEvent_SetPoint(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxTreeEvent * _arg0; + wxPoint * _arg1; + PyObject * _argo0 = 0; + wxPoint temp; + PyObject * _obj1 = 0; + char *_kwnames[] = { "self","pt", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTreeEvent_SetPoint",_kwnames,&_argo0,&_obj1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxTreeEvent_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeEvent_SetPoint. Expected _wxTreeEvent_p."); + return NULL; + } + } +{ + _arg1 = &temp; + if (! wxPoint_helper(_obj1, &_arg1)) + return NULL; +} +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxTreeEvent_SetPoint(_arg0,*_arg1); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; + return _resultobj; +} + #define wxTreeEvent_GetKeyEvent(_swigobj) (_swigobj->GetKeyEvent()) static PyObject *_wrap_wxTreeEvent_GetKeyEvent(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -6426,7 +6381,7 @@ static PyObject *_wrap_wxTreeEvent_GetKeyEvent(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - const wxKeyEvent & _result_ref = wxTreeEvent_GetKeyEvent(_arg0); + const wxKeyEvent & _result_ref = wxTreeEvent_GetKeyEvent(_arg0); _result = (wxKeyEvent *) &_result_ref; wxPyEndAllowThreads(__tstate); @@ -6441,8 +6396,8 @@ static PyObject *_wrap_wxTreeEvent_GetKeyEvent(PyObject *self, PyObject *args, P return _resultobj; } -#define wxTreeEvent_GetCode(_swigobj) (_swigobj->GetCode()) -static PyObject *_wrap_wxTreeEvent_GetCode(PyObject *self, PyObject *args, PyObject *kwargs) { +#define wxTreeEvent_GetKeyCode(_swigobj) (_swigobj->GetKeyCode()) +static PyObject *_wrap_wxTreeEvent_GetKeyCode(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; int _result; wxTreeEvent * _arg0; @@ -6450,18 +6405,18 @@ static PyObject *_wrap_wxTreeEvent_GetCode(PyObject *self, PyObject *args, PyObj char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxTreeEvent_GetCode",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxTreeEvent_GetKeyCode",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxTreeEvent_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeEvent_GetCode. Expected _wxTreeEvent_p."); + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeEvent_GetKeyCode. Expected _wxTreeEvent_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxTreeEvent_GetCode(_arg0); + _result = (int )wxTreeEvent_GetKeyCode(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6469,6 +6424,42 @@ static PyObject *_wrap_wxTreeEvent_GetCode(PyObject *self, PyObject *args, PyObj return _resultobj; } +#define wxTreeEvent_SetKeyEvent(_swigobj,_swigarg0) (_swigobj->SetKeyEvent(_swigarg0)) +static PyObject *_wrap_wxTreeEvent_SetKeyEvent(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxTreeEvent * _arg0; + wxKeyEvent * _arg1; + PyObject * _argo0 = 0; + PyObject * _argo1 = 0; + char *_kwnames[] = { "self","evt", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTreeEvent_SetKeyEvent",_kwnames,&_argo0,&_argo1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxTreeEvent_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeEvent_SetKeyEvent. Expected _wxTreeEvent_p."); + return NULL; + } + } + if (_argo1) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxKeyEvent_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeEvent_SetKeyEvent. Expected _wxKeyEvent_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxTreeEvent_SetKeyEvent(_arg0,*_arg1); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; + return _resultobj; +} + #define wxTreeEvent_GetLabel(_swigobj) (_swigobj->GetLabel()) static PyObject *_wrap_wxTreeEvent_GetLabel(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -6489,17 +6480,119 @@ static PyObject *_wrap_wxTreeEvent_GetLabel(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - const wxString & _result_ref = wxTreeEvent_GetLabel(_arg0); + const wxString & _result_ref = wxTreeEvent_GetLabel(_arg0); _result = (wxString *) &_result_ref; wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } return _resultobj; } +#define wxTreeEvent_SetLabel(_swigobj,_swigarg0) (_swigobj->SetLabel(_swigarg0)) +static PyObject *_wrap_wxTreeEvent_SetLabel(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxTreeEvent * _arg0; + wxString * _arg1; + PyObject * _argo0 = 0; + PyObject * _obj1 = 0; + char *_kwnames[] = { "self","label", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTreeEvent_SetLabel",_kwnames,&_argo0,&_obj1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxTreeEvent_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeEvent_SetLabel. Expected _wxTreeEvent_p."); + return NULL; + } + } +{ + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) + return NULL; +} +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxTreeEvent_SetLabel(_arg0,*_arg1); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; +{ + if (_obj1) + delete _arg1; +} + return _resultobj; +} + +#define wxTreeEvent_IsEditCancelled(_swigobj) (_swigobj->IsEditCancelled()) +static PyObject *_wrap_wxTreeEvent_IsEditCancelled(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + bool _result; + wxTreeEvent * _arg0; + PyObject * _argo0 = 0; + char *_kwnames[] = { "self", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxTreeEvent_IsEditCancelled",_kwnames,&_argo0)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxTreeEvent_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeEvent_IsEditCancelled. Expected _wxTreeEvent_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = (bool )wxTreeEvent_IsEditCancelled(_arg0); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} _resultobj = Py_BuildValue("i",_result); + return _resultobj; +} + +#define wxTreeEvent_SetEditCanceled(_swigobj,_swigarg0) (_swigobj->SetEditCanceled(_swigarg0)) +static PyObject *_wrap_wxTreeEvent_SetEditCanceled(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxTreeEvent * _arg0; + bool _arg1; + PyObject * _argo0 = 0; + int tempbool1; + char *_kwnames[] = { "self","editCancelled", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxTreeEvent_SetEditCanceled",_kwnames,&_argo0,&tempbool1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxTreeEvent_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeEvent_SetEditCanceled. Expected _wxTreeEvent_p."); + return NULL; + } + } + _arg1 = (bool ) tempbool1; +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxTreeEvent_SetEditCanceled(_arg0,_arg1); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; + return _resultobj; +} + static void *SwigwxPyTreeCtrlTowxControl(void *ptr) { wxPyTreeCtrl *src; wxControl *dest; @@ -6540,20 +6633,21 @@ static PyObject *_wrap_new_wxTreeCtrl(PyObject *self, PyObject *args, PyObject * wxWindowID _arg1 = (wxWindowID ) -1; wxPoint * _arg2 = (wxPoint *) &wxDefaultPosition; wxSize * _arg3 = (wxSize *) &wxDefaultSize; - long _arg4 = (long ) (wxTR_HAS_BUTTONS)|(wxTR_LINES_AT_ROOT); + long _arg4 = (long ) (wxTR_DEFAULT_STYLE); wxValidator * _arg5 = (wxValidator *) &wxDefaultValidator; - char * _arg6 = (char *) "wxTreeCtrl"; + wxString * _arg6 = (wxString *) &wxPy_TreeCtrlNameStr; PyObject * _argo0 = 0; wxPoint temp; PyObject * _obj2 = 0; wxSize temp0; PyObject * _obj3 = 0; PyObject * _argo5 = 0; + PyObject * _obj6 = 0; char *_kwnames[] = { "parent","id","pos","size","style","validator","name", NULL }; char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|iOOlOs:new_wxTreeCtrl",_kwnames,&_argo0,&_arg1,&_obj2,&_obj3,&_arg4,&_argo5,&_arg6)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|iOOlOO:new_wxTreeCtrl",_kwnames,&_argo0,&_arg1,&_obj2,&_obj3,&_arg4,&_argo5,&_obj6)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -6575,15 +6669,20 @@ static PyObject *_wrap_new_wxTreeCtrl(PyObject *self, PyObject *args, PyObject * return NULL; } if (_argo5) { - if (_argo5 == Py_None) { _arg5 = NULL; } - else if (SWIG_GetPtrObj(_argo5,(void **) &_arg5,"_wxValidator_p")) { + if (SWIG_GetPtrObj(_argo5,(void **) &_arg5,"_wxValidator_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 6 of new_wxTreeCtrl. Expected _wxValidator_p."); return NULL; } } + if (_obj6) +{ + _arg6 = wxString_in_helper(_obj6); + if (_arg6 == NULL) + return NULL; +} { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxPyTreeCtrl *)new_wxTreeCtrl(_arg0,_arg1,*_arg2,*_arg3,_arg4,*_arg5,_arg6); + _result = (wxPyTreeCtrl *)new_wxTreeCtrl(_arg0,_arg1,*_arg2,*_arg3,_arg4,*_arg5,*_arg6); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6594,6 +6693,10 @@ static PyObject *_wrap_new_wxTreeCtrl(PyObject *self, PyObject *args, PyObject * Py_INCREF(Py_None); _resultobj = Py_None; } +{ + if (_obj6) + delete _arg6; +} return _resultobj; } @@ -6609,7 +6712,7 @@ static PyObject *_wrap_new_wxPreTreeCtrl(PyObject *self, PyObject *args, PyObjec return NULL; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxPyTreeCtrl *)new_wxPreTreeCtrl(); + _result = (wxPyTreeCtrl *)new_wxPreTreeCtrl(); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6632,9 +6735,9 @@ static PyObject *_wrap_wxTreeCtrl_Create(PyObject *self, PyObject *args, PyObjec wxWindowID _arg2 = (wxWindowID ) -1; wxPoint * _arg3 = (wxPoint *) &wxDefaultPosition; wxSize * _arg4 = (wxSize *) &wxDefaultSize; - long _arg5 = (long ) (wxTR_HAS_BUTTONS)|(wxTR_LINES_AT_ROOT); + long _arg5 = (long ) (wxTR_DEFAULT_STYLE); wxValidator * _arg6 = (wxValidator *) &wxDefaultValidator; - char * _arg7 = (char *) "wxTreeCtrl"; + wxString * _arg7 = (wxString *) &wxPy_TreeCtrlNameStr; PyObject * _argo0 = 0; PyObject * _argo1 = 0; wxPoint temp; @@ -6642,10 +6745,11 @@ static PyObject *_wrap_wxTreeCtrl_Create(PyObject *self, PyObject *args, PyObjec wxSize temp0; PyObject * _obj4 = 0; PyObject * _argo6 = 0; + PyObject * _obj7 = 0; char *_kwnames[] = { "self","parent","id","pos","size","style","validator","name", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO|iOOlOs:wxTreeCtrl_Create",_kwnames,&_argo0,&_argo1,&_arg2,&_obj3,&_obj4,&_arg5,&_argo6,&_arg7)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO|iOOlOO:wxTreeCtrl_Create",_kwnames,&_argo0,&_argo1,&_arg2,&_obj3,&_obj4,&_arg5,&_argo6,&_obj7)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -6674,19 +6778,28 @@ static PyObject *_wrap_wxTreeCtrl_Create(PyObject *self, PyObject *args, PyObjec return NULL; } if (_argo6) { - if (_argo6 == Py_None) { _arg6 = NULL; } - else if (SWIG_GetPtrObj(_argo6,(void **) &_arg6,"_wxValidator_p")) { + if (SWIG_GetPtrObj(_argo6,(void **) &_arg6,"_wxValidator_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 7 of wxTreeCtrl_Create. Expected _wxValidator_p."); return NULL; } } + if (_obj7) +{ + _arg7 = wxString_in_helper(_obj7); + if (_arg7 == NULL) + return NULL; +} { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxTreeCtrl_Create(_arg0,_arg1,_arg2,*_arg3,*_arg4,_arg5,*_arg6,_arg7); + _result = (bool )wxTreeCtrl_Create(_arg0,_arg1,_arg2,*_arg3,*_arg4,_arg5,*_arg6,*_arg7); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; } _resultobj = Py_BuildValue("i",_result); +{ + if (_obj7) + delete _arg7; +} return _resultobj; } @@ -6719,7 +6832,7 @@ static PyObject *_wrap_wxTreeCtrl__setCallbackInfo(PyObject *self, PyObject *arg } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl__setCallbackInfo(_arg0,_arg1,_arg2); + wxTreeCtrl__setCallbackInfo(_arg0,_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6748,7 +6861,7 @@ static PyObject *_wrap_wxTreeCtrl_GetCount(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (size_t )wxTreeCtrl_GetCount(_arg0); + _result = (size_t )wxTreeCtrl_GetCount(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6776,7 +6889,7 @@ static PyObject *_wrap_wxTreeCtrl_GetIndent(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (unsigned int )wxTreeCtrl_GetIndent(_arg0); + _result = (unsigned int )wxTreeCtrl_GetIndent(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6804,7 +6917,7 @@ static PyObject *_wrap_wxTreeCtrl_SetIndent(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SetIndent(_arg0,_arg1); + wxTreeCtrl_SetIndent(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6833,7 +6946,7 @@ static PyObject *_wrap_wxTreeCtrl_GetImageList(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxImageList *)wxTreeCtrl_GetImageList(_arg0); + _result = (wxImageList *)wxTreeCtrl_GetImageList(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6861,7 +6974,7 @@ static PyObject *_wrap_wxTreeCtrl_GetStateImageList(PyObject *self, PyObject *ar } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxImageList *)wxTreeCtrl_GetStateImageList(_arg0); + _result = (wxImageList *)wxTreeCtrl_GetStateImageList(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6897,7 +7010,7 @@ static PyObject *_wrap_wxTreeCtrl_SetImageList(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SetImageList(_arg0,_arg1); + wxTreeCtrl_SetImageList(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6934,7 +7047,7 @@ static PyObject *_wrap_wxTreeCtrl_SetStateImageList(PyObject *self, PyObject *ar } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SetStateImageList(_arg0,_arg1); + wxTreeCtrl_SetStateImageList(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -6971,7 +7084,7 @@ static PyObject *_wrap_wxTreeCtrl_AssignImageList(PyObject *self, PyObject *args } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_AssignImageList(_arg0,_arg1); + wxTreeCtrl_AssignImageList(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7008,7 +7121,7 @@ static PyObject *_wrap_wxTreeCtrl_AssignStateImageList(PyObject *self, PyObject } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_AssignStateImageList(_arg0,_arg1); + wxTreeCtrl_AssignStateImageList(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7037,7 +7150,7 @@ static PyObject *_wrap_wxTreeCtrl_GetSpacing(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (unsigned int )wxTreeCtrl_GetSpacing(_arg0); + _result = (unsigned int )wxTreeCtrl_GetSpacing(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7065,7 +7178,7 @@ static PyObject *_wrap_wxTreeCtrl_SetSpacing(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SetSpacing(_arg0,_arg1); + wxTreeCtrl_SetSpacing(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7095,20 +7208,23 @@ static PyObject *_wrap_wxTreeCtrl_GetItemText(PyObject *self, PyObject *args, Py } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetItemText. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxString (wxTreeCtrl_GetItemText(_arg0,*_arg1)); + _result = new wxString (wxTreeCtrl_GetItemText(_arg0,*_arg1)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } { delete _result; @@ -7138,15 +7254,14 @@ static PyObject *_wrap_wxTreeCtrl_GetItemImage(PyObject *self, PyObject *args, P } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetItemImage. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxTreeCtrl_GetItemImage(_arg0,*_arg1,_arg2); + _result = (int )wxTreeCtrl_GetItemImage(_arg0,*_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7175,15 +7290,14 @@ static PyObject *_wrap_wxTreeCtrl_GetItemSelectedImage(PyObject *self, PyObject } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetItemSelectedImage. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxTreeCtrl_GetItemSelectedImage(_arg0,*_arg1); + _result = (int )wxTreeCtrl_GetItemSelectedImage(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7213,33 +7327,19 @@ static PyObject *_wrap_wxTreeCtrl_SetItemText(PyObject *self, PyObject *args, Py } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_SetItemText. Expected _wxTreeItemId_p."); return NULL; } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj2) && !PyUnicode_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj2, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg2 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg2 = wxString_in_helper(_obj2); + if (_arg2 == NULL) return NULL; - } - _arg2 = new wxString(PyString_AS_STRING(_obj2), PyString_GET_SIZE(_obj2)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SetItemText(_arg0,*_arg1,*_arg2); + wxTreeCtrl_SetItemText(_arg0,*_arg1,*_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7274,15 +7374,14 @@ static PyObject *_wrap_wxTreeCtrl_SetItemImage(PyObject *self, PyObject *args, P } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_SetItemImage. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SetItemImage(_arg0,*_arg1,_arg2,_arg3); + wxTreeCtrl_SetItemImage(_arg0,*_arg1,_arg2,_arg3); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7312,15 +7411,14 @@ static PyObject *_wrap_wxTreeCtrl_SetItemSelectedImage(PyObject *self, PyObject } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_SetItemSelectedImage. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SetItemSelectedImage(_arg0,*_arg1,_arg2); + wxTreeCtrl_SetItemSelectedImage(_arg0,*_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7351,8 +7449,7 @@ static PyObject *_wrap_wxTreeCtrl_SetItemHasChildren(PyObject *self, PyObject *a } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_SetItemHasChildren. Expected _wxTreeItemId_p."); return NULL; } @@ -7360,7 +7457,7 @@ static PyObject *_wrap_wxTreeCtrl_SetItemHasChildren(PyObject *self, PyObject *a _arg2 = (bool ) tempbool2; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SetItemHasChildren(_arg0,*_arg1,_arg2); + wxTreeCtrl_SetItemHasChildren(_arg0,*_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7399,15 +7496,14 @@ static PyObject *_wrap_wxTreeCtrl_GetItemData(PyObject *self, PyObject *args, Py } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetItemData. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxPyTreeItemData *)wxPyTreeCtrl_GetItemData(_arg0,*_arg1); + _result = (wxPyTreeItemData *)wxPyTreeCtrl_GetItemData(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7446,8 +7542,7 @@ static PyObject *_wrap_wxTreeCtrl_SetItemData(PyObject *self, PyObject *args, Py } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_SetItemData. Expected _wxTreeItemId_p."); return NULL; } @@ -7461,7 +7556,7 @@ static PyObject *_wrap_wxTreeCtrl_SetItemData(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxPyTreeCtrl_SetItemData(_arg0,*_arg1,_arg2); + wxPyTreeCtrl_SetItemData(_arg0,*_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7499,15 +7594,14 @@ static PyObject *_wrap_wxTreeCtrl_GetPyData(PyObject *self, PyObject *args, PyOb } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetPyData. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (PyObject *)wxPyTreeCtrl_GetPyData(_arg0,*_arg1); + _result = (PyObject *)wxPyTreeCtrl_GetPyData(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7547,8 +7641,7 @@ static PyObject *_wrap_wxTreeCtrl_SetPyData(PyObject *self, PyObject *args, PyOb } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_SetPyData. Expected _wxTreeItemId_p."); return NULL; } @@ -7558,7 +7651,7 @@ static PyObject *_wrap_wxTreeCtrl_SetPyData(PyObject *self, PyObject *args, PyOb } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxPyTreeCtrl_SetPyData(_arg0,*_arg1,_arg2); + wxPyTreeCtrl_SetPyData(_arg0,*_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7567,6 +7660,120 @@ static PyObject *_wrap_wxTreeCtrl_SetPyData(PyObject *self, PyObject *args, PyOb return _resultobj; } +#define wxTreeCtrl_GetItemTextColour(_swigobj,_swigarg0) (_swigobj->GetItemTextColour(_swigarg0)) +static PyObject *_wrap_wxTreeCtrl_GetItemTextColour(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxColour * _result; + wxPyTreeCtrl * _arg0; + wxTreeItemId * _arg1; + PyObject * _argo0 = 0; + PyObject * _argo1 = 0; + char *_kwnames[] = { "self","item", NULL }; + char _ptemp[128]; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTreeCtrl_GetItemTextColour",_kwnames,&_argo0,&_argo1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyTreeCtrl_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeCtrl_GetItemTextColour. Expected _wxPyTreeCtrl_p."); + return NULL; + } + } + if (_argo1) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetItemTextColour. Expected _wxTreeItemId_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = new wxColour (wxTreeCtrl_GetItemTextColour(_arg0,*_arg1)); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} SWIG_MakePtr(_ptemp, (void *) _result,"_wxColour_p"); + _resultobj = Py_BuildValue("s",_ptemp); + return _resultobj; +} + +#define wxTreeCtrl_GetItemBackgroundColour(_swigobj,_swigarg0) (_swigobj->GetItemBackgroundColour(_swigarg0)) +static PyObject *_wrap_wxTreeCtrl_GetItemBackgroundColour(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxColour * _result; + wxPyTreeCtrl * _arg0; + wxTreeItemId * _arg1; + PyObject * _argo0 = 0; + PyObject * _argo1 = 0; + char *_kwnames[] = { "self","item", NULL }; + char _ptemp[128]; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTreeCtrl_GetItemBackgroundColour",_kwnames,&_argo0,&_argo1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyTreeCtrl_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeCtrl_GetItemBackgroundColour. Expected _wxPyTreeCtrl_p."); + return NULL; + } + } + if (_argo1) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetItemBackgroundColour. Expected _wxTreeItemId_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = new wxColour (wxTreeCtrl_GetItemBackgroundColour(_arg0,*_arg1)); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} SWIG_MakePtr(_ptemp, (void *) _result,"_wxColour_p"); + _resultobj = Py_BuildValue("s",_ptemp); + return _resultobj; +} + +#define wxTreeCtrl_GetItemFont(_swigobj,_swigarg0) (_swigobj->GetItemFont(_swigarg0)) +static PyObject *_wrap_wxTreeCtrl_GetItemFont(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxFont * _result; + wxPyTreeCtrl * _arg0; + wxTreeItemId * _arg1; + PyObject * _argo0 = 0; + PyObject * _argo1 = 0; + char *_kwnames[] = { "self","item", NULL }; + char _ptemp[128]; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTreeCtrl_GetItemFont",_kwnames,&_argo0,&_argo1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyTreeCtrl_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeCtrl_GetItemFont. Expected _wxPyTreeCtrl_p."); + return NULL; + } + } + if (_argo1) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetItemFont. Expected _wxTreeItemId_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = new wxFont (wxTreeCtrl_GetItemFont(_arg0,*_arg1)); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} SWIG_MakePtr(_ptemp, (void *) _result,"_wxFont_p"); + _resultobj = Py_BuildValue("s",_ptemp); + return _resultobj; +} + #define wxTreeCtrl_IsVisible(_swigobj,_swigarg0) (_swigobj->IsVisible(_swigarg0)) static PyObject *_wrap_wxTreeCtrl_IsVisible(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -7588,15 +7795,14 @@ static PyObject *_wrap_wxTreeCtrl_IsVisible(PyObject *self, PyObject *args, PyOb } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_IsVisible. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxTreeCtrl_IsVisible(_arg0,*_arg1); + _result = (bool )wxTreeCtrl_IsVisible(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7625,15 +7831,14 @@ static PyObject *_wrap_wxTreeCtrl_ItemHasChildren(PyObject *self, PyObject *args } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_ItemHasChildren. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxTreeCtrl_ItemHasChildren(_arg0,*_arg1); + _result = (bool )wxTreeCtrl_ItemHasChildren(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7662,15 +7867,14 @@ static PyObject *_wrap_wxTreeCtrl_IsExpanded(PyObject *self, PyObject *args, PyO } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_IsExpanded. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxTreeCtrl_IsExpanded(_arg0,*_arg1); + _result = (bool )wxTreeCtrl_IsExpanded(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7699,15 +7903,14 @@ static PyObject *_wrap_wxTreeCtrl_IsSelected(PyObject *self, PyObject *args, PyO } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_IsSelected. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxTreeCtrl_IsSelected(_arg0,*_arg1); + _result = (bool )wxTreeCtrl_IsSelected(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7736,7 +7939,7 @@ static PyObject *_wrap_wxTreeCtrl_GetRootItem(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_GetRootItem(_arg0)); + _result = new wxTreeItemId (wxTreeCtrl_GetRootItem(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7766,7 +7969,7 @@ static PyObject *_wrap_wxTreeCtrl_GetSelection(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_GetSelection(_arg0)); + _result = new wxTreeItemId (wxTreeCtrl_GetSelection(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7775,7 +7978,7 @@ static PyObject *_wrap_wxTreeCtrl_GetSelection(PyObject *self, PyObject *args, P return _resultobj; } -#define wxTreeCtrl_GetItemParent(_swigobj,_swigarg0) (_swigobj->GetParent(_swigarg0)) +#define wxTreeCtrl_GetItemParent(_swigobj,_swigarg0) (_swigobj->GetItemParent(_swigarg0)) static PyObject *_wrap_wxTreeCtrl_GetItemParent(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; wxTreeItemId * _result; @@ -7797,15 +8000,14 @@ static PyObject *_wrap_wxTreeCtrl_GetItemParent(PyObject *self, PyObject *args, } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetItemParent. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_GetItemParent(_arg0,*_arg1)); + _result = new wxTreeItemId (wxTreeCtrl_GetItemParent(_arg0,*_arg1)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7822,7 +8024,7 @@ static PyObject * wxPyTreeCtrl_GetSelections(wxPyTreeCtrl *self) { num = self->GetSelections(array); for (x=0; x < num; x++) { wxTreeItemId *tii = new wxTreeItemId(array.Item(x)); - PyObject* item = wxPyConstructObject((void*)tii, "wxTreeItemId", TRUE); + PyObject* item = wxPyConstructObject((void*)tii, wxT("wxTreeItemId"), TRUE); PyList_Append(rval, item); } wxPyEndBlockThreads(); @@ -7847,7 +8049,7 @@ static PyObject *_wrap_wxTreeCtrl_GetSelections(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (PyObject *)wxPyTreeCtrl_GetSelections(_arg0); + _result = (PyObject *)wxPyTreeCtrl_GetSelections(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7880,8 +8082,7 @@ static PyObject *_wrap_wxTreeCtrl_GetChildrenCount(PyObject *self, PyObject *arg } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetChildrenCount. Expected _wxTreeItemId_p."); return NULL; } @@ -7889,7 +8090,7 @@ static PyObject *_wrap_wxTreeCtrl_GetChildrenCount(PyObject *self, PyObject *arg _arg2 = (bool ) tempbool2; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (size_t )wxTreeCtrl_GetChildrenCount(_arg0,*_arg1,_arg2); + _result = (size_t )wxTreeCtrl_GetChildrenCount(_arg0,*_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7903,7 +8104,7 @@ static PyObject *_wrap_wxTreeCtrl_GetFirstChild(PyObject *self, PyObject *args, wxTreeItemId * _result; wxPyTreeCtrl * _arg0; wxTreeItemId * _arg1; - long * _arg2; + long * _arg2 = (long *) &longzero; PyObject * _argo0 = 0; PyObject * _argo1 = 0; long temp; @@ -7912,7 +8113,7 @@ static PyObject *_wrap_wxTreeCtrl_GetFirstChild(PyObject *self, PyObject *args, char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxTreeCtrl_GetFirstChild",_kwnames,&_argo0,&_argo1,&_obj2)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO|O:wxTreeCtrl_GetFirstChild",_kwnames,&_argo0,&_argo1,&_obj2)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -7922,19 +8123,19 @@ static PyObject *_wrap_wxTreeCtrl_GetFirstChild(PyObject *self, PyObject *args, } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetFirstChild. Expected _wxTreeItemId_p."); return NULL; } } + if (_obj2) { temp = (long) PyInt_AsLong(_obj2); _arg2 = &temp; } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_GetFirstChild(_arg0,*_arg1,*_arg2)); + _result = new wxTreeItemId (wxTreeCtrl_GetFirstChild(_arg0,*_arg1,*_arg2)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -7973,8 +8174,7 @@ static PyObject *_wrap_wxTreeCtrl_GetNextChild(PyObject *self, PyObject *args, P } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetNextChild. Expected _wxTreeItemId_p."); return NULL; } @@ -7985,7 +8185,7 @@ static PyObject *_wrap_wxTreeCtrl_GetNextChild(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_GetNextChild(_arg0,*_arg1,*_arg2)); + _result = new wxTreeItemId (wxTreeCtrl_GetNextChild(_arg0,*_arg1,*_arg2)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8021,15 +8221,14 @@ static PyObject *_wrap_wxTreeCtrl_GetNextSibling(PyObject *self, PyObject *args, } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetNextSibling. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_GetNextSibling(_arg0,*_arg1)); + _result = new wxTreeItemId (wxTreeCtrl_GetNextSibling(_arg0,*_arg1)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8060,15 +8259,14 @@ static PyObject *_wrap_wxTreeCtrl_GetPrevSibling(PyObject *self, PyObject *args, } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetPrevSibling. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_GetPrevSibling(_arg0,*_arg1)); + _result = new wxTreeItemId (wxTreeCtrl_GetPrevSibling(_arg0,*_arg1)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8098,7 +8296,7 @@ static PyObject *_wrap_wxTreeCtrl_GetFirstVisibleItem(PyObject *self, PyObject * } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_GetFirstVisibleItem(_arg0)); + _result = new wxTreeItemId (wxTreeCtrl_GetFirstVisibleItem(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8129,15 +8327,14 @@ static PyObject *_wrap_wxTreeCtrl_GetNextVisible(PyObject *self, PyObject *args, } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetNextVisible. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_GetNextVisible(_arg0,*_arg1)); + _result = new wxTreeItemId (wxTreeCtrl_GetNextVisible(_arg0,*_arg1)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8168,15 +8365,14 @@ static PyObject *_wrap_wxTreeCtrl_GetPrevVisible(PyObject *self, PyObject *args, } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetPrevVisible. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_GetPrevVisible(_arg0,*_arg1)); + _result = new wxTreeItemId (wxTreeCtrl_GetPrevVisible(_arg0,*_arg1)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8207,15 +8403,14 @@ static PyObject *_wrap_wxTreeCtrl_GetLastChild(PyObject *self, PyObject *args, P } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetLastChild. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_GetLastChild(_arg0,*_arg1)); + _result = new wxTreeItemId (wxTreeCtrl_GetLastChild(_arg0,*_arg1)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8250,22 +8445,9 @@ static PyObject *_wrap_wxTreeCtrl_AddRoot(PyObject *self, PyObject *args, PyObje } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg1 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) return NULL; - } - _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1)); -#endif } if (_argo4) { if (_argo4 == Py_None) { _arg4 = NULL; } @@ -8276,7 +8458,7 @@ static PyObject *_wrap_wxTreeCtrl_AddRoot(PyObject *self, PyObject *args, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_AddRoot(_arg0,*_arg1,_arg2,_arg3,_arg4)); + _result = new wxTreeItemId (wxTreeCtrl_AddRoot(_arg0,*_arg1,_arg2,_arg3,_arg4)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8317,29 +8499,15 @@ static PyObject *_wrap_wxTreeCtrl_PrependItem(PyObject *self, PyObject *args, Py } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_PrependItem. Expected _wxTreeItemId_p."); return NULL; } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj2) && !PyUnicode_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj2, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg2 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg2 = wxString_in_helper(_obj2); + if (_arg2 == NULL) return NULL; - } - _arg2 = new wxString(PyString_AS_STRING(_obj2), PyString_GET_SIZE(_obj2)); -#endif } if (_argo5) { if (_argo5 == Py_None) { _arg5 = NULL; } @@ -8350,7 +8518,7 @@ static PyObject *_wrap_wxTreeCtrl_PrependItem(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_PrependItem(_arg0,*_arg1,*_arg2,_arg3,_arg4,_arg5)); + _result = new wxTreeItemId (wxTreeCtrl_PrependItem(_arg0,*_arg1,*_arg2,_arg3,_arg4,_arg5)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8393,36 +8561,21 @@ static PyObject *_wrap_wxTreeCtrl_InsertItem(PyObject *self, PyObject *args, PyO } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_InsertItem. Expected _wxTreeItemId_p."); return NULL; } } if (_argo2) { - if (_argo2 == Py_None) { _arg2 = NULL; } - else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of wxTreeCtrl_InsertItem. Expected _wxTreeItemId_p."); return NULL; } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj3) && !PyUnicode_Check(_obj3)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg3 = wxString_in_helper(_obj3); + if (_arg3 == NULL) return NULL; - } - if (PyString_AsStringAndSize(_obj3, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg3 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj3)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - _arg3 = new wxString(PyString_AS_STRING(_obj3), PyString_GET_SIZE(_obj3)); -#endif } if (_argo6) { if (_argo6 == Py_None) { _arg6 = NULL; } @@ -8433,7 +8586,7 @@ static PyObject *_wrap_wxTreeCtrl_InsertItem(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_InsertItem(_arg0,*_arg1,*_arg2,*_arg3,_arg4,_arg5,_arg6)); + _result = new wxTreeItemId (wxTreeCtrl_InsertItem(_arg0,*_arg1,*_arg2,*_arg3,_arg4,_arg5,_arg6)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8456,7 +8609,7 @@ static PyObject *_wrap_wxTreeCtrl_InsertItemBefore(PyObject *self, PyObject *arg wxString * _arg3; int _arg4 = (int ) -1; int _arg5 = (int ) -1; - wxTreeItemData * _arg6 = (wxTreeItemData *) NULL; + wxPyTreeItemData * _arg6 = (wxPyTreeItemData *) NULL; PyObject * _argo0 = 0; PyObject * _argo1 = 0; PyObject * _obj3 = 0; @@ -8475,40 +8628,26 @@ static PyObject *_wrap_wxTreeCtrl_InsertItemBefore(PyObject *self, PyObject *arg } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_InsertItemBefore. Expected _wxTreeItemId_p."); return NULL; } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj3) && !PyUnicode_Check(_obj3)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj3, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg3 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj3)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg3 = wxString_in_helper(_obj3); + if (_arg3 == NULL) return NULL; - } - _arg3 = new wxString(PyString_AS_STRING(_obj3), PyString_GET_SIZE(_obj3)); -#endif } if (_argo6) { if (_argo6 == Py_None) { _arg6 = NULL; } - else if (SWIG_GetPtrObj(_argo6,(void **) &_arg6,"_wxTreeItemData_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 7 of wxTreeCtrl_InsertItemBefore. Expected _wxTreeItemData_p."); + else if (SWIG_GetPtrObj(_argo6,(void **) &_arg6,"_wxPyTreeItemData_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 7 of wxTreeCtrl_InsertItemBefore. Expected _wxPyTreeItemData_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_InsertItemBefore(_arg0,*_arg1,_arg2,*_arg3,_arg4,_arg5,_arg6)); + _result = new wxTreeItemId (wxTreeCtrl_InsertItemBefore(_arg0,*_arg1,_arg2,*_arg3,_arg4,_arg5,_arg6)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8549,29 +8688,15 @@ static PyObject *_wrap_wxTreeCtrl_AppendItem(PyObject *self, PyObject *args, PyO } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_AppendItem. Expected _wxTreeItemId_p."); return NULL; } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj2) && !PyUnicode_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj2, &tmpPtr, &tmpSize) == -1) + _arg2 = wxString_in_helper(_obj2); + if (_arg2 == NULL) return NULL; - _arg2 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj2)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - _arg2 = new wxString(PyString_AS_STRING(_obj2), PyString_GET_SIZE(_obj2)); -#endif } if (_argo5) { if (_argo5 == Py_None) { _arg5 = NULL; } @@ -8582,7 +8707,7 @@ static PyObject *_wrap_wxTreeCtrl_AppendItem(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_AppendItem(_arg0,*_arg1,*_arg2,_arg3,_arg4,_arg5)); + _result = new wxTreeItemId (wxTreeCtrl_AppendItem(_arg0,*_arg1,*_arg2,_arg3,_arg4,_arg5)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8615,15 +8740,14 @@ static PyObject *_wrap_wxTreeCtrl_Delete(PyObject *self, PyObject *args, PyObjec } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_Delete. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_Delete(_arg0,*_arg1); + wxTreeCtrl_Delete(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8652,15 +8776,14 @@ static PyObject *_wrap_wxTreeCtrl_DeleteChildren(PyObject *self, PyObject *args, } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_DeleteChildren. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_DeleteChildren(_arg0,*_arg1); + wxTreeCtrl_DeleteChildren(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8688,7 +8811,7 @@ static PyObject *_wrap_wxTreeCtrl_DeleteAllItems(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_DeleteAllItems(_arg0); + wxTreeCtrl_DeleteAllItems(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8717,15 +8840,14 @@ static PyObject *_wrap_wxTreeCtrl_Expand(PyObject *self, PyObject *args, PyObjec } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_Expand. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_Expand(_arg0,*_arg1); + wxTreeCtrl_Expand(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8754,15 +8876,14 @@ static PyObject *_wrap_wxTreeCtrl_Collapse(PyObject *self, PyObject *args, PyObj } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_Collapse. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_Collapse(_arg0,*_arg1); + wxTreeCtrl_Collapse(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8791,15 +8912,14 @@ static PyObject *_wrap_wxTreeCtrl_CollapseAndReset(PyObject *self, PyObject *arg } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_CollapseAndReset. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_CollapseAndReset(_arg0,*_arg1); + wxTreeCtrl_CollapseAndReset(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8828,15 +8948,14 @@ static PyObject *_wrap_wxTreeCtrl_Toggle(PyObject *self, PyObject *args, PyObjec } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_Toggle. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_Toggle(_arg0,*_arg1); + wxTreeCtrl_Toggle(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8864,7 +8983,7 @@ static PyObject *_wrap_wxTreeCtrl_Unselect(PyObject *self, PyObject *args, PyObj } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_Unselect(_arg0); + wxTreeCtrl_Unselect(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8892,7 +9011,7 @@ static PyObject *_wrap_wxTreeCtrl_UnselectAll(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_UnselectAll(_arg0); + wxTreeCtrl_UnselectAll(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8921,15 +9040,14 @@ static PyObject *_wrap_wxTreeCtrl_SelectItem(PyObject *self, PyObject *args, PyO } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_SelectItem. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SelectItem(_arg0,*_arg1); + wxTreeCtrl_SelectItem(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8958,15 +9076,14 @@ static PyObject *_wrap_wxTreeCtrl_EnsureVisible(PyObject *self, PyObject *args, } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_EnsureVisible. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_EnsureVisible(_arg0,*_arg1); + wxTreeCtrl_EnsureVisible(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -8995,15 +9112,14 @@ static PyObject *_wrap_wxTreeCtrl_ScrollTo(PyObject *self, PyObject *args, PyObj } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_ScrollTo. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_ScrollTo(_arg0,*_arg1); + wxTreeCtrl_ScrollTo(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9012,36 +9128,27 @@ static PyObject *_wrap_wxTreeCtrl_ScrollTo(PyObject *self, PyObject *args, PyObj return _resultobj; } -#define wxTreeCtrl_EditLabel(_swigobj,_swigarg0) (_swigobj->EditLabel(_swigarg0)) -static PyObject *_wrap_wxTreeCtrl_EditLabel(PyObject *self, PyObject *args, PyObject *kwargs) { +#define wxTreeCtrl_GetEditControl(_swigobj) (_swigobj->GetEditControl()) +static PyObject *_wrap_wxTreeCtrl_GetEditControl(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; wxTextCtrl * _result; wxPyTreeCtrl * _arg0; - wxTreeItemId * _arg1; PyObject * _argo0 = 0; - PyObject * _argo1 = 0; - char *_kwnames[] = { "self","item", NULL }; + char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTreeCtrl_EditLabel",_kwnames,&_argo0,&_argo1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxTreeCtrl_GetEditControl",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyTreeCtrl_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeCtrl_EditLabel. Expected _wxPyTreeCtrl_p."); - return NULL; - } - } - if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_EditLabel. Expected _wxTreeItemId_p."); + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeCtrl_GetEditControl. Expected _wxPyTreeCtrl_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxTextCtrl *)wxTreeCtrl_EditLabel(_arg0,*_arg1); + _result = (wxTextCtrl *)wxTreeCtrl_GetEditControl(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9049,31 +9156,39 @@ static PyObject *_wrap_wxTreeCtrl_EditLabel(PyObject *self, PyObject *args, PyOb return _resultobj; } -#define wxTreeCtrl_GetEditControl(_swigobj) (_swigobj->GetEditControl()) -static PyObject *_wrap_wxTreeCtrl_GetEditControl(PyObject *self, PyObject *args, PyObject *kwargs) { +#define wxTreeCtrl_EditLabel(_swigobj,_swigarg0) (_swigobj->EditLabel(_swigarg0)) +static PyObject *_wrap_wxTreeCtrl_EditLabel(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; - wxTextCtrl * _result; wxPyTreeCtrl * _arg0; + wxTreeItemId * _arg1; PyObject * _argo0 = 0; - char *_kwnames[] = { "self", NULL }; + PyObject * _argo1 = 0; + char *_kwnames[] = { "self","item", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxTreeCtrl_GetEditControl",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTreeCtrl_EditLabel",_kwnames,&_argo0,&_argo1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyTreeCtrl_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeCtrl_GetEditControl. Expected _wxPyTreeCtrl_p."); + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeCtrl_EditLabel. Expected _wxPyTreeCtrl_p."); + return NULL; + } + } + if (_argo1) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_EditLabel. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxTextCtrl *)wxTreeCtrl_GetEditControl(_arg0); + wxTreeCtrl_EditLabel(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; -}{ _resultobj = wxPyMake_wxObject(_result); } +} Py_INCREF(Py_None); + _resultobj = Py_None; return _resultobj; } @@ -9098,15 +9213,14 @@ static PyObject *_wrap_wxTreeCtrl_EndEditLabel(PyObject *self, PyObject *args, P } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_EndEditLabel. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_EndEditLabel(_arg0,*_arg1,_arg2); + wxTreeCtrl_EndEditLabel(_arg0,*_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9135,15 +9249,14 @@ static PyObject *_wrap_wxTreeCtrl_SortChildren(PyObject *self, PyObject *args, P } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_SortChildren. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SortChildren(_arg0,*_arg1); + wxTreeCtrl_SortChildren(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9173,15 +9286,14 @@ static PyObject *_wrap_wxTreeCtrl_SetItemBold(PyObject *self, PyObject *args, Py } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_SetItemBold. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SetItemBold(_arg0,*_arg1,_arg2); + wxTreeCtrl_SetItemBold(_arg0,*_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9211,15 +9323,14 @@ static PyObject *_wrap_wxTreeCtrl_IsBold(PyObject *self, PyObject *args, PyObjec } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_IsBold. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxTreeCtrl_IsBold(_arg0,*_arg1); + _result = (bool )wxTreeCtrl_IsBold(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9261,7 +9372,7 @@ static PyObject *_wrap_wxTreeCtrl_HitTest(PyObject *self, PyObject *args, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxTreeCtrl_HitTest(_arg0,*_arg1,*_arg2)); + _result = new wxTreeItemId (wxTreeCtrl_HitTest(_arg0,*_arg1,*_arg2)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9298,8 +9409,7 @@ static PyObject *_wrap_wxTreeCtrl_SetItemTextColour(PyObject *self, PyObject *ar } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_SetItemTextColour. Expected _wxTreeItemId_p."); return NULL; } @@ -9311,7 +9421,7 @@ static PyObject *_wrap_wxTreeCtrl_SetItemTextColour(PyObject *self, PyObject *ar } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SetItemTextColour(_arg0,*_arg1,*_arg2); + wxTreeCtrl_SetItemTextColour(_arg0,*_arg1,*_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9343,8 +9453,7 @@ static PyObject *_wrap_wxTreeCtrl_SetItemBackgroundColour(PyObject *self, PyObje } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_SetItemBackgroundColour. Expected _wxTreeItemId_p."); return NULL; } @@ -9356,7 +9465,7 @@ static PyObject *_wrap_wxTreeCtrl_SetItemBackgroundColour(PyObject *self, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SetItemBackgroundColour(_arg0,*_arg1,*_arg2); + wxTreeCtrl_SetItemBackgroundColour(_arg0,*_arg1,*_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9387,22 +9496,20 @@ static PyObject *_wrap_wxTreeCtrl_SetItemFont(PyObject *self, PyObject *args, Py } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_SetItemFont. Expected _wxTreeItemId_p."); return NULL; } } if (_argo2) { - if (_argo2 == Py_None) { _arg2 = NULL; } - else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxFont_p")) { + if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxFont_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of wxTreeCtrl_SetItemFont. Expected _wxFont_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SetItemFont(_arg0,*_arg1,*_arg2); + wxTreeCtrl_SetItemFont(_arg0,*_arg1,*_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9432,15 +9539,14 @@ static PyObject *_wrap_wxTreeCtrl_SetItemDropHighlight(PyObject *self, PyObject } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_SetItemDropHighlight. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxTreeCtrl_SetItemDropHighlight(_arg0,*_arg1,_arg2); + wxTreeCtrl_SetItemDropHighlight(_arg0,*_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9454,7 +9560,7 @@ static PyObject * wxPyTreeCtrl_GetBoundingRect(wxPyTreeCtrl *self,const wxTreeIt if (self->GetBoundingRect(item, rect, textOnly)) { wxPyBeginBlockThreads(); wxRect* r = new wxRect(rect); - PyObject* val = wxPyConstructObject((void*)r, "wxRect"); + PyObject* val = wxPyConstructObject((void*)r, wxT("wxRect"), 1); wxPyEndBlockThreads(); return val; } @@ -9484,15 +9590,14 @@ static PyObject *_wrap_wxTreeCtrl_GetBoundingRect(PyObject *self, PyObject *args } } if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { + if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxTreeItemId_p")) { PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_GetBoundingRect. Expected _wxTreeItemId_p."); return NULL; } } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (PyObject *)wxPyTreeCtrl_GetBoundingRect(_arg0,*_arg1,_arg2); + _result = (PyObject *)wxPyTreeCtrl_GetBoundingRect(_arg0,*_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9526,46 +9631,20 @@ static PyObject *_wrap_new_wxDirItemData(PyObject *self, PyObject *args, PyObjec self = self; if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOi:new_wxDirItemData",_kwnames,&_obj0,&_obj1,&tempbool2)) return NULL; -{ -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj0) && !PyUnicode_Check(_obj0)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj0, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg0 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj0)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - _arg0 = new wxString(PyString_AS_STRING(_obj0), PyString_GET_SIZE(_obj0)); -#endif -} -{ -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1) +{ + _arg0 = wxString_in_helper(_obj0); + if (_arg0 == NULL) return NULL; - _arg1 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); +} +{ + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) return NULL; - } - _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1)); -#endif } _arg2 = (bool ) tempbool2; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxDirItemData *)new_wxDirItemData(*_arg0,*_arg1,_arg2); + _result = (wxDirItemData *)new_wxDirItemData(*_arg0,*_arg1,_arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9607,26 +9686,13 @@ static PyObject *_wrap_wxDirItemData_SetNewDirName(PyObject *self, PyObject *arg } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg1 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) return NULL; - } - _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxDirItemData_SetNewDirName(_arg0,*_arg1); + wxDirItemData_SetNewDirName(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9660,31 +9726,22 @@ static PyObject *_wrap_wxDirItemData_m_path_set(PyObject *self, PyObject *args, } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg1 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) return NULL; - } - _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxString *)wxDirItemData_m_path_set(_arg0,_arg1); + _result = (wxString *)wxDirItemData_m_path_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } { if (_obj1) @@ -9713,12 +9770,16 @@ static PyObject *_wrap_wxDirItemData_m_path_get(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxString *)wxDirItemData_m_path_get(_arg0); + _result = (wxString *)wxDirItemData_m_path_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } return _resultobj; } @@ -9744,31 +9805,22 @@ static PyObject *_wrap_wxDirItemData_m_name_set(PyObject *self, PyObject *args, } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg1 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) return NULL; - } - _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxString *)wxDirItemData_m_name_set(_arg0,_arg1); + _result = (wxString *)wxDirItemData_m_name_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } { if (_obj1) @@ -9797,12 +9849,16 @@ static PyObject *_wrap_wxDirItemData_m_name_get(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxString *)wxDirItemData_m_name_get(_arg0); + _result = (wxString *)wxDirItemData_m_name_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } return _resultobj; } @@ -9830,7 +9886,7 @@ static PyObject *_wrap_wxDirItemData_m_isHidden_set(PyObject *self, PyObject *ar _arg1 = (bool ) tempbool1; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxDirItemData_m_isHidden_set(_arg0,_arg1); + _result = (bool )wxDirItemData_m_isHidden_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9858,7 +9914,7 @@ static PyObject *_wrap_wxDirItemData_m_isHidden_get(PyObject *self, PyObject *ar } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxDirItemData_m_isHidden_get(_arg0); + _result = (bool )wxDirItemData_m_isHidden_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9889,7 +9945,7 @@ static PyObject *_wrap_wxDirItemData_m_isExpanded_set(PyObject *self, PyObject * _arg1 = (bool ) tempbool1; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxDirItemData_m_isExpanded_set(_arg0,_arg1); + _result = (bool )wxDirItemData_m_isExpanded_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9917,7 +9973,7 @@ static PyObject *_wrap_wxDirItemData_m_isExpanded_get(PyObject *self, PyObject * } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxDirItemData_m_isExpanded_get(_arg0); + _result = (bool )wxDirItemData_m_isExpanded_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9948,7 +10004,7 @@ static PyObject *_wrap_wxDirItemData_m_isDir_set(PyObject *self, PyObject *args, _arg1 = (bool ) tempbool1; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxDirItemData_m_isDir_set(_arg0,_arg1); + _result = (bool )wxDirItemData_m_isDir_set(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -9976,7 +10032,7 @@ static PyObject *_wrap_wxDirItemData_m_isDir_get(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxDirItemData_m_isDir_get(_arg0); + _result = (bool )wxDirItemData_m_isDir_get(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10022,23 +10078,26 @@ static PyObject *_wrap_new_wxGenericDirCtrl(PyObject *self, PyObject *args, PyOb wxGenericDirCtrl * _result; wxWindow * _arg0; wxWindowID _arg1 = (wxWindowID ) -1; - char * _arg2 = (char *) wxDirDialogDefaultFolderStr; + wxString * _arg2 = (wxString *) &wxPyDirDialogDefaultFolderStr; wxPoint * _arg3 = (wxPoint *) &wxDefaultPosition; wxSize * _arg4 = (wxSize *) &wxDefaultSize; long _arg5 = (long ) (wxDIRCTRL_3D_INTERNAL)|wxSUNKEN_BORDER; - char * _arg6 = (char *) wxEmptyString; + wxString * _arg6 = (wxString *) &wxPyEmptyString; int _arg7 = (int ) 0; - char * _arg8 = (char *) "dirCtrl"; + wxString * _arg8 = (wxString *) &wxPy_TreeCtrlNameStr; PyObject * _argo0 = 0; + PyObject * _obj2 = 0; wxPoint temp; PyObject * _obj3 = 0; wxSize temp0; PyObject * _obj4 = 0; + PyObject * _obj6 = 0; + PyObject * _obj8 = 0; char *_kwnames[] = { "parent","id","dir","pos","size","style","filter","defaultFilter","name", NULL }; char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|isOOlsis:new_wxGenericDirCtrl",_kwnames,&_argo0,&_arg1,&_arg2,&_obj3,&_obj4,&_arg5,&_arg6,&_arg7,&_arg8)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|iOOOlOiO:new_wxGenericDirCtrl",_kwnames,&_argo0,&_arg1,&_obj2,&_obj3,&_obj4,&_arg5,&_obj6,&_arg7,&_obj8)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -10047,6 +10106,12 @@ static PyObject *_wrap_new_wxGenericDirCtrl(PyObject *self, PyObject *args, PyOb return NULL; } } + if (_obj2) +{ + _arg2 = wxString_in_helper(_obj2); + if (_arg2 == NULL) + return NULL; +} if (_obj3) { _arg3 = &temp; @@ -10058,10 +10123,22 @@ static PyObject *_wrap_new_wxGenericDirCtrl(PyObject *self, PyObject *args, PyOb _arg4 = &temp0; if (! wxSize_helper(_obj4, &_arg4)) return NULL; +} + if (_obj6) +{ + _arg6 = wxString_in_helper(_obj6); + if (_arg6 == NULL) + return NULL; +} + if (_obj8) +{ + _arg8 = wxString_in_helper(_obj8); + if (_arg8 == NULL) + return NULL; } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxGenericDirCtrl *)new_wxGenericDirCtrl(_arg0,_arg1,_arg2,*_arg3,*_arg4,_arg5,_arg6,_arg7,_arg8); + _result = (wxGenericDirCtrl *)new_wxGenericDirCtrl(_arg0,_arg1,*_arg2,*_arg3,*_arg4,_arg5,*_arg6,_arg7,*_arg8); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10072,6 +10149,18 @@ static PyObject *_wrap_new_wxGenericDirCtrl(PyObject *self, PyObject *args, PyOb Py_INCREF(Py_None); _resultobj = Py_None; } +{ + if (_obj2) + delete _arg2; +} +{ + if (_obj6) + delete _arg6; +} +{ + if (_obj8) + delete _arg8; +} return _resultobj; } @@ -10087,7 +10176,7 @@ static PyObject *_wrap_new_wxPreGenericDirCtrl(PyObject *self, PyObject *args, P return NULL; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxGenericDirCtrl *)new_wxPreGenericDirCtrl(); + _result = (wxGenericDirCtrl *)new_wxPreGenericDirCtrl(); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10108,23 +10197,26 @@ static PyObject *_wrap_wxGenericDirCtrl_Create(PyObject *self, PyObject *args, P wxGenericDirCtrl * _arg0; wxWindow * _arg1; wxWindowID _arg2 = (wxWindowID ) -1; - char * _arg3 = (char *) wxDirDialogDefaultFolderStr; + wxString * _arg3 = (wxString *) &wxPyDirDialogDefaultFolderStr; wxPoint * _arg4 = (wxPoint *) &wxDefaultPosition; wxSize * _arg5 = (wxSize *) &wxDefaultSize; long _arg6 = (long ) (wxDIRCTRL_3D_INTERNAL)|wxSUNKEN_BORDER; - char * _arg7 = (char *) wxEmptyString; + wxString * _arg7 = (wxString *) &wxPyEmptyString; int _arg8 = (int ) 0; - char * _arg9 = (char *) "dirCtrl"; + wxString * _arg9 = (wxString *) &wxPy_TreeCtrlNameStr; PyObject * _argo0 = 0; PyObject * _argo1 = 0; + PyObject * _obj3 = 0; wxPoint temp; PyObject * _obj4 = 0; wxSize temp0; PyObject * _obj5 = 0; + PyObject * _obj7 = 0; + PyObject * _obj9 = 0; char *_kwnames[] = { "self","parent","id","dir","pos","size","style","filter","defaultFilter","name", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO|isOOlsis:wxGenericDirCtrl_Create",_kwnames,&_argo0,&_argo1,&_arg2,&_arg3,&_obj4,&_obj5,&_arg6,&_arg7,&_arg8,&_arg9)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO|iOOOlOiO:wxGenericDirCtrl_Create",_kwnames,&_argo0,&_argo1,&_arg2,&_obj3,&_obj4,&_obj5,&_arg6,&_obj7,&_arg8,&_obj9)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -10140,6 +10232,12 @@ static PyObject *_wrap_wxGenericDirCtrl_Create(PyObject *self, PyObject *args, P return NULL; } } + if (_obj3) +{ + _arg3 = wxString_in_helper(_obj3); + if (_arg3 == NULL) + return NULL; +} if (_obj4) { _arg4 = &temp; @@ -10151,14 +10249,38 @@ static PyObject *_wrap_wxGenericDirCtrl_Create(PyObject *self, PyObject *args, P _arg5 = &temp0; if (! wxSize_helper(_obj5, &_arg5)) return NULL; +} + if (_obj7) +{ + _arg7 = wxString_in_helper(_obj7); + if (_arg7 == NULL) + return NULL; +} + if (_obj9) +{ + _arg9 = wxString_in_helper(_obj9); + if (_arg9 == NULL) + return NULL; } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxGenericDirCtrl_Create(_arg0,_arg1,_arg2,_arg3,*_arg4,*_arg5,_arg6,_arg7,_arg8,_arg9); + _result = (bool )wxGenericDirCtrl_Create(_arg0,_arg1,_arg2,*_arg3,*_arg4,*_arg5,_arg6,*_arg7,_arg8,*_arg9); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; } _resultobj = Py_BuildValue("i",_result); +{ + if (_obj3) + delete _arg3; +} +{ + if (_obj7) + delete _arg7; +} +{ + if (_obj9) + delete _arg9; +} return _resultobj; } @@ -10183,26 +10305,13 @@ static PyObject *_wrap_wxGenericDirCtrl_ExpandPath(PyObject *self, PyObject *arg } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg1 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) return NULL; - } - _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxGenericDirCtrl_ExpandPath(_arg0,*_arg1); + _result = (bool )wxGenericDirCtrl_ExpandPath(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10234,12 +10343,16 @@ static PyObject *_wrap_wxGenericDirCtrl_GetDefaultPath(PyObject *self, PyObject } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxString (wxGenericDirCtrl_GetDefaultPath(_arg0)); + _result = new wxString (wxGenericDirCtrl_GetDefaultPath(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } { delete _result; @@ -10267,26 +10380,13 @@ static PyObject *_wrap_wxGenericDirCtrl_SetDefaultPath(PyObject *self, PyObject } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg1 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) return NULL; - } - _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxGenericDirCtrl_SetDefaultPath(_arg0,*_arg1); + wxGenericDirCtrl_SetDefaultPath(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10319,12 +10419,16 @@ static PyObject *_wrap_wxGenericDirCtrl_GetPath(PyObject *self, PyObject *args, } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxString (wxGenericDirCtrl_GetPath(_arg0)); + _result = new wxString (wxGenericDirCtrl_GetPath(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } { delete _result; @@ -10352,12 +10456,16 @@ static PyObject *_wrap_wxGenericDirCtrl_GetFilePath(PyObject *self, PyObject *ar } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxString (wxGenericDirCtrl_GetFilePath(_arg0)); + _result = new wxString (wxGenericDirCtrl_GetFilePath(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } { delete _result; @@ -10385,26 +10493,13 @@ static PyObject *_wrap_wxGenericDirCtrl_SetPath(PyObject *self, PyObject *args, } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg1 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) return NULL; - } - _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxGenericDirCtrl_SetPath(_arg0,*_arg1); + wxGenericDirCtrl_SetPath(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10439,7 +10534,7 @@ static PyObject *_wrap_wxGenericDirCtrl_ShowHidden(PyObject *self, PyObject *arg _arg1 = (bool ) tempbool1; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxGenericDirCtrl_ShowHidden(_arg0,_arg1); + wxGenericDirCtrl_ShowHidden(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10468,7 +10563,7 @@ static PyObject *_wrap_wxGenericDirCtrl_GetShowHidden(PyObject *self, PyObject * } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxGenericDirCtrl_GetShowHidden(_arg0); + _result = (bool )wxGenericDirCtrl_GetShowHidden(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10496,12 +10591,16 @@ static PyObject *_wrap_wxGenericDirCtrl_GetFilter(PyObject *self, PyObject *args } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxString (wxGenericDirCtrl_GetFilter(_arg0)); + _result = new wxString (wxGenericDirCtrl_GetFilter(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; }{ +#if wxUSE_UNICODE + _resultobj = PyUnicode_FromWideChar(_result->c_str(), _result->Len()); +#else _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +#endif } { delete _result; @@ -10529,26 +10628,13 @@ static PyObject *_wrap_wxGenericDirCtrl_SetFilter(PyObject *self, PyObject *args } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); - return NULL; - } - if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1) - return NULL; - _arg1 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) return NULL; - } - _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1)); -#endif } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxGenericDirCtrl_SetFilter(_arg0,*_arg1); + wxGenericDirCtrl_SetFilter(_arg0,*_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10581,7 +10667,7 @@ static PyObject *_wrap_wxGenericDirCtrl_GetFilterIndex(PyObject *self, PyObject } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxGenericDirCtrl_GetFilterIndex(_arg0); + _result = (int )wxGenericDirCtrl_GetFilterIndex(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10609,7 +10695,7 @@ static PyObject *_wrap_wxGenericDirCtrl_SetFilterIndex(PyObject *self, PyObject } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxGenericDirCtrl_SetFilterIndex(_arg0,_arg1); + wxGenericDirCtrl_SetFilterIndex(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10639,7 +10725,7 @@ static PyObject *_wrap_wxGenericDirCtrl_GetRootId(PyObject *self, PyObject *args } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = new wxTreeItemId (wxGenericDirCtrl_GetRootId(_arg0)); + _result = new wxTreeItemId (wxGenericDirCtrl_GetRootId(_arg0)); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10655,7 +10741,6 @@ static PyObject *_wrap_wxGenericDirCtrl_GetTreeCtrl(PyObject *self, PyObject *ar wxGenericDirCtrl * _arg0; PyObject * _argo0 = 0; char *_kwnames[] = { "self", NULL }; - char _ptemp[128]; self = self; if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxGenericDirCtrl_GetTreeCtrl",_kwnames,&_argo0)) @@ -10669,17 +10754,11 @@ static PyObject *_wrap_wxGenericDirCtrl_GetTreeCtrl(PyObject *self, PyObject *ar } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxTreeCtrl *)wxGenericDirCtrl_GetTreeCtrl(_arg0); + _result = (wxTreeCtrl *)wxGenericDirCtrl_GetTreeCtrl(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; -} if (_result) { - SWIG_MakePtr(_ptemp, (char *) _result,"_wxTreeCtrl_p"); - _resultobj = Py_BuildValue("s",_ptemp); - } else { - Py_INCREF(Py_None); - _resultobj = Py_None; - } +}{ _resultobj = wxPyMake_wxObject(_result); } return _resultobj; } @@ -10704,7 +10783,7 @@ static PyObject *_wrap_wxGenericDirCtrl_GetFilterListCtrl(PyObject *self, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxDirFilterListCtrl *)wxGenericDirCtrl_GetFilterListCtrl(_arg0); + _result = (wxDirFilterListCtrl *)wxGenericDirCtrl_GetFilterListCtrl(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10718,6 +10797,34 @@ static PyObject *_wrap_wxGenericDirCtrl_GetFilterListCtrl(PyObject *self, PyObje return _resultobj; } +#define wxGenericDirCtrl_ReCreateTree(_swigobj) (_swigobj->ReCreateTree()) +static PyObject *_wrap_wxGenericDirCtrl_ReCreateTree(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxGenericDirCtrl * _arg0; + PyObject * _argo0 = 0; + char *_kwnames[] = { "self", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxGenericDirCtrl_ReCreateTree",_kwnames,&_argo0)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGenericDirCtrl_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGenericDirCtrl_ReCreateTree. Expected _wxGenericDirCtrl_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxGenericDirCtrl_ReCreateTree(_arg0); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; + return _resultobj; +} + static void *SwigwxDirFilterListCtrlTowxChoice(void *ptr) { wxDirFilterListCtrl *src; wxChoice *dest; @@ -10807,7 +10914,7 @@ static PyObject *_wrap_new_wxDirFilterListCtrl(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxDirFilterListCtrl *)new_wxDirFilterListCtrl(_arg0,_arg1,*_arg2,*_arg3,_arg4); + _result = (wxDirFilterListCtrl *)new_wxDirFilterListCtrl(_arg0,_arg1,*_arg2,*_arg3,_arg4); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10833,7 +10940,7 @@ static PyObject *_wrap_new_wxPreDirFilterListCtrl(PyObject *self, PyObject *args return NULL; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxDirFilterListCtrl *)new_wxPreDirFilterListCtrl(); + _result = (wxDirFilterListCtrl *)new_wxPreDirFilterListCtrl(); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10896,7 +11003,7 @@ static PyObject *_wrap_wxDirFilterListCtrl_Create(PyObject *self, PyObject *args } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (bool )wxDirFilterListCtrl_Create(_arg0,_arg1,_arg2,*_arg3,*_arg4,_arg5); + _result = (bool )wxDirFilterListCtrl_Create(_arg0,_arg1,_arg2,*_arg3,*_arg4,_arg5); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -10925,43 +11032,168 @@ static PyObject *_wrap_wxDirFilterListCtrl_FillFilterList(PyObject *self, PyObje } } { -#if PYTHON_API_VERSION >= 1009 - char* tmpPtr; int tmpSize; - if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) + return NULL; +} +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxDirFilterListCtrl_FillFilterList(_arg0,*_arg1,_arg2); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; +{ + if (_obj1) + delete _arg1; +} + return _resultobj; +} + +#define new_wxFileIconsTable() (new wxFileIconsTable()) +static PyObject *_wrap_new_wxFileIconsTable(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxFileIconsTable * _result; + char *_kwnames[] = { NULL }; + char _ptemp[128]; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,":new_wxFileIconsTable",_kwnames)) return NULL; +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = (wxFileIconsTable *)new_wxFileIconsTable(); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} if (_result) { + SWIG_MakePtr(_ptemp, (char *) _result,"_wxFileIconsTable_p"); + _resultobj = Py_BuildValue("s",_ptemp); + } else { + Py_INCREF(Py_None); + _resultobj = Py_None; } - if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1) + return _resultobj; +} + +#define delete_wxFileIconsTable(_swigobj) (delete _swigobj) +static PyObject *_wrap_delete_wxFileIconsTable(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxFileIconsTable * _arg0; + PyObject * _argo0 = 0; + char *_kwnames[] = { "self", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxFileIconsTable",_kwnames,&_argo0)) return NULL; - _arg1 = new wxString(tmpPtr, tmpSize); -#else - if (!PyString_Check(_obj1)) { - PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxFileIconsTable_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of delete_wxFileIconsTable. Expected _wxFileIconsTable_p."); return NULL; + } } - _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1)); -#endif -} { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxDirFilterListCtrl_FillFilterList(_arg0,*_arg1,_arg2); + delete_wxFileIconsTable(_arg0); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; } Py_INCREF(Py_None); _resultobj = Py_None; + return _resultobj; +} + +#define wxFileIconsTable_GetIconID(_swigobj,_swigarg0,_swigarg1) (_swigobj->GetIconID(_swigarg0,_swigarg1)) +static PyObject *_wrap_wxFileIconsTable_GetIconID(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + int _result; + wxFileIconsTable * _arg0; + wxString * _arg1; + wxString * _arg2 = (wxString *) &wxEmptyString; + PyObject * _argo0 = 0; + PyObject * _obj1 = 0; + PyObject * _obj2 = 0; + char *_kwnames[] = { "self","extension","mime", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO|O:wxFileIconsTable_GetIconID",_kwnames,&_argo0,&_obj1,&_obj2)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxFileIconsTable_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxFileIconsTable_GetIconID. Expected _wxFileIconsTable_p."); + return NULL; + } + } +{ + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) + return NULL; +} + if (_obj2) +{ + _arg2 = wxString_in_helper(_obj2); + if (_arg2 == NULL) + return NULL; +} +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = (int )wxFileIconsTable_GetIconID(_arg0,*_arg1,*_arg2); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} _resultobj = Py_BuildValue("i",_result); { if (_obj1) delete _arg1; } +{ + if (_obj2) + delete _arg2; +} + return _resultobj; +} + +#define wxFileIconsTable_GetSmallImageList(_swigobj) (_swigobj->GetSmallImageList()) +static PyObject *_wrap_wxFileIconsTable_GetSmallImageList(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxImageList * _result; + wxFileIconsTable * _arg0; + PyObject * _argo0 = 0; + char *_kwnames[] = { "self", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxFileIconsTable_GetSmallImageList",_kwnames,&_argo0)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxFileIconsTable_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxFileIconsTable_GetSmallImageList. Expected _wxFileIconsTable_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = (wxImageList *)wxFileIconsTable_GetSmallImageList(_arg0); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +}{ _resultobj = wxPyMake_wxObject(_result); } return _resultobj; } static PyMethodDef controls2cMethods[] = { + { "wxFileIconsTable_GetSmallImageList", (PyCFunction) _wrap_wxFileIconsTable_GetSmallImageList, METH_VARARGS | METH_KEYWORDS }, + { "wxFileIconsTable_GetIconID", (PyCFunction) _wrap_wxFileIconsTable_GetIconID, METH_VARARGS | METH_KEYWORDS }, + { "delete_wxFileIconsTable", (PyCFunction) _wrap_delete_wxFileIconsTable, METH_VARARGS | METH_KEYWORDS }, + { "new_wxFileIconsTable", (PyCFunction) _wrap_new_wxFileIconsTable, METH_VARARGS | METH_KEYWORDS }, { "wxDirFilterListCtrl_FillFilterList", (PyCFunction) _wrap_wxDirFilterListCtrl_FillFilterList, METH_VARARGS | METH_KEYWORDS }, { "wxDirFilterListCtrl_Create", (PyCFunction) _wrap_wxDirFilterListCtrl_Create, METH_VARARGS | METH_KEYWORDS }, { "new_wxPreDirFilterListCtrl", (PyCFunction) _wrap_new_wxPreDirFilterListCtrl, METH_VARARGS | METH_KEYWORDS }, { "new_wxDirFilterListCtrl", (PyCFunction) _wrap_new_wxDirFilterListCtrl, METH_VARARGS | METH_KEYWORDS }, + { "wxGenericDirCtrl_ReCreateTree", (PyCFunction) _wrap_wxGenericDirCtrl_ReCreateTree, METH_VARARGS | METH_KEYWORDS }, { "wxGenericDirCtrl_GetFilterListCtrl", (PyCFunction) _wrap_wxGenericDirCtrl_GetFilterListCtrl, METH_VARARGS | METH_KEYWORDS }, { "wxGenericDirCtrl_GetTreeCtrl", (PyCFunction) _wrap_wxGenericDirCtrl_GetTreeCtrl, METH_VARARGS | METH_KEYWORDS }, { "wxGenericDirCtrl_GetRootId", (PyCFunction) _wrap_wxGenericDirCtrl_GetRootId, METH_VARARGS | METH_KEYWORDS }, @@ -11002,8 +11234,8 @@ static PyMethodDef controls2cMethods[] = { { "wxTreeCtrl_SetItemBold", (PyCFunction) _wrap_wxTreeCtrl_SetItemBold, METH_VARARGS | METH_KEYWORDS }, { "wxTreeCtrl_SortChildren", (PyCFunction) _wrap_wxTreeCtrl_SortChildren, METH_VARARGS | METH_KEYWORDS }, { "wxTreeCtrl_EndEditLabel", (PyCFunction) _wrap_wxTreeCtrl_EndEditLabel, METH_VARARGS | METH_KEYWORDS }, - { "wxTreeCtrl_GetEditControl", (PyCFunction) _wrap_wxTreeCtrl_GetEditControl, METH_VARARGS | METH_KEYWORDS }, { "wxTreeCtrl_EditLabel", (PyCFunction) _wrap_wxTreeCtrl_EditLabel, METH_VARARGS | METH_KEYWORDS }, + { "wxTreeCtrl_GetEditControl", (PyCFunction) _wrap_wxTreeCtrl_GetEditControl, METH_VARARGS | METH_KEYWORDS }, { "wxTreeCtrl_ScrollTo", (PyCFunction) _wrap_wxTreeCtrl_ScrollTo, METH_VARARGS | METH_KEYWORDS }, { "wxTreeCtrl_EnsureVisible", (PyCFunction) _wrap_wxTreeCtrl_EnsureVisible, METH_VARARGS | METH_KEYWORDS }, { "wxTreeCtrl_SelectItem", (PyCFunction) _wrap_wxTreeCtrl_SelectItem, METH_VARARGS | METH_KEYWORDS }, @@ -11038,6 +11270,9 @@ static PyMethodDef controls2cMethods[] = { { "wxTreeCtrl_IsExpanded", (PyCFunction) _wrap_wxTreeCtrl_IsExpanded, METH_VARARGS | METH_KEYWORDS }, { "wxTreeCtrl_ItemHasChildren", (PyCFunction) _wrap_wxTreeCtrl_ItemHasChildren, METH_VARARGS | METH_KEYWORDS }, { "wxTreeCtrl_IsVisible", (PyCFunction) _wrap_wxTreeCtrl_IsVisible, METH_VARARGS | METH_KEYWORDS }, + { "wxTreeCtrl_GetItemFont", (PyCFunction) _wrap_wxTreeCtrl_GetItemFont, METH_VARARGS | METH_KEYWORDS }, + { "wxTreeCtrl_GetItemBackgroundColour", (PyCFunction) _wrap_wxTreeCtrl_GetItemBackgroundColour, METH_VARARGS | METH_KEYWORDS }, + { "wxTreeCtrl_GetItemTextColour", (PyCFunction) _wrap_wxTreeCtrl_GetItemTextColour, METH_VARARGS | METH_KEYWORDS }, { "wxTreeCtrl_SetPyData", (PyCFunction) _wrap_wxTreeCtrl_SetPyData, METH_VARARGS | METH_KEYWORDS }, { "wxTreeCtrl_GetPyData", (PyCFunction) _wrap_wxTreeCtrl_GetPyData, METH_VARARGS | METH_KEYWORDS }, { "wxTreeCtrl_SetItemData", (PyCFunction) _wrap_wxTreeCtrl_SetItemData, METH_VARARGS | METH_KEYWORDS }, @@ -11064,11 +11299,18 @@ static PyMethodDef controls2cMethods[] = { { "wxTreeCtrl_Create", (PyCFunction) _wrap_wxTreeCtrl_Create, METH_VARARGS | METH_KEYWORDS }, { "new_wxPreTreeCtrl", (PyCFunction) _wrap_new_wxPreTreeCtrl, METH_VARARGS | METH_KEYWORDS }, { "new_wxTreeCtrl", (PyCFunction) _wrap_new_wxTreeCtrl, METH_VARARGS | METH_KEYWORDS }, + { "wxTreeEvent_SetEditCanceled", (PyCFunction) _wrap_wxTreeEvent_SetEditCanceled, METH_VARARGS | METH_KEYWORDS }, + { "wxTreeEvent_IsEditCancelled", (PyCFunction) _wrap_wxTreeEvent_IsEditCancelled, METH_VARARGS | METH_KEYWORDS }, + { "wxTreeEvent_SetLabel", (PyCFunction) _wrap_wxTreeEvent_SetLabel, METH_VARARGS | METH_KEYWORDS }, { "wxTreeEvent_GetLabel", (PyCFunction) _wrap_wxTreeEvent_GetLabel, METH_VARARGS | METH_KEYWORDS }, - { "wxTreeEvent_GetCode", (PyCFunction) _wrap_wxTreeEvent_GetCode, METH_VARARGS | METH_KEYWORDS }, + { "wxTreeEvent_SetKeyEvent", (PyCFunction) _wrap_wxTreeEvent_SetKeyEvent, METH_VARARGS | METH_KEYWORDS }, + { "wxTreeEvent_GetKeyCode", (PyCFunction) _wrap_wxTreeEvent_GetKeyCode, METH_VARARGS | METH_KEYWORDS }, { "wxTreeEvent_GetKeyEvent", (PyCFunction) _wrap_wxTreeEvent_GetKeyEvent, METH_VARARGS | METH_KEYWORDS }, + { "wxTreeEvent_SetPoint", (PyCFunction) _wrap_wxTreeEvent_SetPoint, METH_VARARGS | METH_KEYWORDS }, { "wxTreeEvent_GetPoint", (PyCFunction) _wrap_wxTreeEvent_GetPoint, METH_VARARGS | METH_KEYWORDS }, + { "wxTreeEvent_SetOldItem", (PyCFunction) _wrap_wxTreeEvent_SetOldItem, METH_VARARGS | METH_KEYWORDS }, { "wxTreeEvent_GetOldItem", (PyCFunction) _wrap_wxTreeEvent_GetOldItem, METH_VARARGS | METH_KEYWORDS }, + { "wxTreeEvent_SetItem", (PyCFunction) _wrap_wxTreeEvent_SetItem, METH_VARARGS | METH_KEYWORDS }, { "wxTreeEvent_GetItem", (PyCFunction) _wrap_wxTreeEvent_GetItem, METH_VARARGS | METH_KEYWORDS }, { "new_wxTreeEvent", (PyCFunction) _wrap_new_wxTreeEvent, METH_VARARGS | METH_KEYWORDS }, { "wxTreeItemData_SetId", (PyCFunction) _wrap_wxTreeItemData_SetId, METH_VARARGS | METH_KEYWORDS }, @@ -11101,7 +11343,12 @@ static PyMethodDef controls2cMethods[] = { { "wxListView_Create", (PyCFunction) _wrap_wxListView_Create, METH_VARARGS | METH_KEYWORDS }, { "new_wxPreListView", (PyCFunction) _wrap_new_wxPreListView, METH_VARARGS | METH_KEYWORDS }, { "new_wxListView", (PyCFunction) _wrap_new_wxListView, METH_VARARGS | METH_KEYWORDS }, + { "wxListCtrl_GetMainWindow", (PyCFunction) _wrap_wxListCtrl_GetMainWindow, METH_VARARGS | METH_KEYWORDS }, { "wxListCtrl_SortItems", (PyCFunction) _wrap_wxListCtrl_SortItems, METH_VARARGS | METH_KEYWORDS }, + { "wxListCtrl_GetItemBackgroundColour", (PyCFunction) _wrap_wxListCtrl_GetItemBackgroundColour, METH_VARARGS | METH_KEYWORDS }, + { "wxListCtrl_SetItemBackgroundColour", (PyCFunction) _wrap_wxListCtrl_SetItemBackgroundColour, METH_VARARGS | METH_KEYWORDS }, + { "wxListCtrl_GetItemTextColour", (PyCFunction) _wrap_wxListCtrl_GetItemTextColour, METH_VARARGS | METH_KEYWORDS }, + { "wxListCtrl_SetItemTextColour", (PyCFunction) _wrap_wxListCtrl_SetItemTextColour, METH_VARARGS | METH_KEYWORDS }, { "wxListCtrl_ScrollList", (PyCFunction) _wrap_wxListCtrl_ScrollList, METH_VARARGS | METH_KEYWORDS }, { "wxListCtrl_SetItemCount", (PyCFunction) _wrap_wxListCtrl_SetItemCount, METH_VARARGS | METH_KEYWORDS }, { "wxListCtrl_InsertColumn", (PyCFunction) _wrap_wxListCtrl_InsertColumn, METH_VARARGS | METH_KEYWORDS }, @@ -11175,19 +11422,13 @@ static PyMethodDef controls2cMethods[] = { { "wxListEvent_GetPoint", (PyCFunction) _wrap_wxListEvent_GetPoint, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_GetColumn", (PyCFunction) _wrap_wxListEvent_GetColumn, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_GetIndex", (PyCFunction) _wrap_wxListEvent_GetIndex, METH_VARARGS | METH_KEYWORDS }, - { "wxListEvent_GetCode", (PyCFunction) _wrap_wxListEvent_GetCode, METH_VARARGS | METH_KEYWORDS }, + { "wxListEvent_GetKeyCode", (PyCFunction) _wrap_wxListEvent_GetKeyCode, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_m_item_get", (PyCFunction) _wrap_wxListEvent_m_item_get, METH_VARARGS | METH_KEYWORDS }, - { "wxListEvent_m_item_set", (PyCFunction) _wrap_wxListEvent_m_item_set, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_m_pointDrag_get", (PyCFunction) _wrap_wxListEvent_m_pointDrag_get, METH_VARARGS | METH_KEYWORDS }, - { "wxListEvent_m_pointDrag_set", (PyCFunction) _wrap_wxListEvent_m_pointDrag_set, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_m_col_get", (PyCFunction) _wrap_wxListEvent_m_col_get, METH_VARARGS | METH_KEYWORDS }, - { "wxListEvent_m_col_set", (PyCFunction) _wrap_wxListEvent_m_col_set, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_m_itemIndex_get", (PyCFunction) _wrap_wxListEvent_m_itemIndex_get, METH_VARARGS | METH_KEYWORDS }, - { "wxListEvent_m_itemIndex_set", (PyCFunction) _wrap_wxListEvent_m_itemIndex_set, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_m_oldItemIndex_get", (PyCFunction) _wrap_wxListEvent_m_oldItemIndex_get, METH_VARARGS | METH_KEYWORDS }, - { "wxListEvent_m_oldItemIndex_set", (PyCFunction) _wrap_wxListEvent_m_oldItemIndex_set, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_m_code_get", (PyCFunction) _wrap_wxListEvent_m_code_get, METH_VARARGS | METH_KEYWORDS }, - { "wxListEvent_m_code_set", (PyCFunction) _wrap_wxListEvent_m_code_set, METH_VARARGS | METH_KEYWORDS }, { "new_wxListEvent", (PyCFunction) _wrap_new_wxListEvent, METH_VARARGS | METH_KEYWORDS }, { "wxListItem_m_width_get", (PyCFunction) _wrap_wxListItem_m_width_get, METH_VARARGS | METH_KEYWORDS }, { "wxListItem_m_width_set", (PyCFunction) _wrap_wxListItem_m_width_set, METH_VARARGS | METH_KEYWORDS }, @@ -11318,7 +11559,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxObject","_wxDirItemData",SwigwxDirItemDataTowxObject}, { "_wxObject","_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxObject}, { "_wxObject","_wxTreeEvent",SwigwxTreeEventTowxObject}, - { "_wxObject","_wxPyTreeItemData",SwigwxPyTreeItemDataTowxObject}, { "_wxObject","_wxListView",SwigwxListViewTowxObject}, { "_wxObject","_wxPyListCtrl",SwigwxPyListCtrlTowxObject}, { "_wxObject","_wxListEvent",SwigwxListEventTowxObject}, @@ -11486,20 +11726,20 @@ SWIGEXPORT(void) initcontrols2c() { PyDict_SetItemString(d,"wxLIST_FORMAT_CENTER", PyInt_FromLong((long) wxLIST_FORMAT_CENTER)); PyDict_SetItemString(d,"wxTR_NO_BUTTONS", PyInt_FromLong((long) wxTR_NO_BUTTONS)); PyDict_SetItemString(d,"wxTR_HAS_BUTTONS", PyInt_FromLong((long) wxTR_HAS_BUTTONS)); - PyDict_SetItemString(d,"wxTR_TWIST_BUTTONS", PyInt_FromLong((long) wxTR_TWIST_BUTTONS)); PyDict_SetItemString(d,"wxTR_NO_LINES", PyInt_FromLong((long) wxTR_NO_LINES)); - PyDict_SetItemString(d,"wxTR_MAC_BUTTONS", PyInt_FromLong((long) wxTR_MAC_BUTTONS)); - PyDict_SetItemString(d,"wxTR_AQUA_BUTTONS", PyInt_FromLong((long) wxTR_AQUA_BUTTONS)); + PyDict_SetItemString(d,"wxTR_LINES_AT_ROOT", PyInt_FromLong((long) wxTR_LINES_AT_ROOT)); PyDict_SetItemString(d,"wxTR_SINGLE", PyInt_FromLong((long) wxTR_SINGLE)); PyDict_SetItemString(d,"wxTR_MULTIPLE", PyInt_FromLong((long) wxTR_MULTIPLE)); PyDict_SetItemString(d,"wxTR_EXTENDED", PyInt_FromLong((long) wxTR_EXTENDED)); - PyDict_SetItemString(d,"wxTR_FULL_ROW_HIGHLIGHT", PyInt_FromLong((long) wxTR_FULL_ROW_HIGHLIGHT)); + PyDict_SetItemString(d,"wxTR_HAS_VARIABLE_ROW_HEIGHT", PyInt_FromLong((long) wxTR_HAS_VARIABLE_ROW_HEIGHT)); PyDict_SetItemString(d,"wxTR_EDIT_LABELS", PyInt_FromLong((long) wxTR_EDIT_LABELS)); - PyDict_SetItemString(d,"wxTR_LINES_AT_ROOT", PyInt_FromLong((long) wxTR_LINES_AT_ROOT)); PyDict_SetItemString(d,"wxTR_HIDE_ROOT", PyInt_FromLong((long) wxTR_HIDE_ROOT)); PyDict_SetItemString(d,"wxTR_ROW_LINES", PyInt_FromLong((long) wxTR_ROW_LINES)); - PyDict_SetItemString(d,"wxTR_HAS_VARIABLE_ROW_HEIGHT", PyInt_FromLong((long) wxTR_HAS_VARIABLE_ROW_HEIGHT)); + PyDict_SetItemString(d,"wxTR_FULL_ROW_HIGHLIGHT", PyInt_FromLong((long) wxTR_FULL_ROW_HIGHLIGHT)); PyDict_SetItemString(d,"wxTR_DEFAULT_STYLE", PyInt_FromLong((long) wxTR_DEFAULT_STYLE)); + PyDict_SetItemString(d,"wxTR_TWIST_BUTTONS", PyInt_FromLong((long) wxTR_TWIST_BUTTONS)); + PyDict_SetItemString(d,"wxTR_MAC_BUTTONS", PyInt_FromLong((long) wxTR_MAC_BUTTONS)); + PyDict_SetItemString(d,"wxTR_AQUA_BUTTONS", PyInt_FromLong((long) wxTR_AQUA_BUTTONS)); PyDict_SetItemString(d,"wxTreeItemIcon_Normal", PyInt_FromLong((long) wxTreeItemIcon_Normal)); PyDict_SetItemString(d,"wxTreeItemIcon_Selected", PyInt_FromLong((long) wxTreeItemIcon_Selected)); PyDict_SetItemString(d,"wxTreeItemIcon_Expanded", PyInt_FromLong((long) wxTreeItemIcon_Expanded)); @@ -11537,15 +11777,28 @@ SWIGEXPORT(void) initcontrols2c() { PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK)); PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK)); PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_END_DRAG", PyInt_FromLong((long) wxEVT_COMMAND_TREE_END_DRAG)); + PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_STATE_IMAGE_CLICK", PyInt_FromLong((long) wxEVT_COMMAND_TREE_STATE_IMAGE_CLICK)); PyDict_SetItemString(d,"wxDIRCTRL_DIR_ONLY", PyInt_FromLong((long) wxDIRCTRL_DIR_ONLY)); PyDict_SetItemString(d,"wxDIRCTRL_SELECT_FIRST", PyInt_FromLong((long) wxDIRCTRL_SELECT_FIRST)); PyDict_SetItemString(d,"wxDIRCTRL_SHOW_FILTERS", PyInt_FromLong((long) wxDIRCTRL_SHOW_FILTERS)); PyDict_SetItemString(d,"wxDIRCTRL_3D_INTERNAL", PyInt_FromLong((long) wxDIRCTRL_3D_INTERNAL)); + PyDict_SetItemString(d,"wxDIRCTRL_EDIT_LABELS", PyInt_FromLong((long) wxDIRCTRL_EDIT_LABELS)); + PyDict_SetItemString(d,"wxID_TREECTRL", PyInt_FromLong((long) wxID_TREECTRL)); + PyDict_SetItemString(d,"wxID_FILTERLISTCTRL", PyInt_FromLong((long) wxID_FILTERLISTCTRL)); // Map renamed classes back to their common name for OOR wxPyPtrTypeMap_Add("wxTreeItemData", "wxPyTreeItemData"); wxPyPtrTypeMap_Add("wxTreeCtrl", "wxPyTreeCtrl"); wxPyPtrTypeMap_Add("wxListCtrl", "wxPyListCtrl"); + PyDict_SetItemString(d,"wxFileIconsTable_folder", PyInt_FromLong((long) wxFileIconsTable::folder)); + PyDict_SetItemString(d,"wxFileIconsTable_folder_open", PyInt_FromLong((long) wxFileIconsTable::folder_open)); + PyDict_SetItemString(d,"wxFileIconsTable_computer", PyInt_FromLong((long) wxFileIconsTable::computer)); + PyDict_SetItemString(d,"wxFileIconsTable_drive", PyInt_FromLong((long) wxFileIconsTable::drive)); + PyDict_SetItemString(d,"wxFileIconsTable_cdrom", PyInt_FromLong((long) wxFileIconsTable::cdrom)); + PyDict_SetItemString(d,"wxFileIconsTable_floppy", PyInt_FromLong((long) wxFileIconsTable::floppy)); + PyDict_SetItemString(d,"wxFileIconsTable_removeable", PyInt_FromLong((long) wxFileIconsTable::removeable)); + PyDict_SetItemString(d,"wxFileIconsTable_file", PyInt_FromLong((long) wxFileIconsTable::file)); + PyDict_SetItemString(d,"wxFileIconsTable_executable", PyInt_FromLong((long) wxFileIconsTable::executable)); { int i; for (i = 0; _swig_mapping[i].n1; i++)