X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/3afe2fd691f7b46d8a076c6c45663005c5173d49..9f8a9f548973be3033383aa235edadcf858336e8:/wxPython/src/helpers.cpp?ds=sidebyside diff --git a/wxPython/src/helpers.cpp b/wxPython/src/helpers.cpp index 1d662540a5..3984fd52b0 100644 --- a/wxPython/src/helpers.cpp +++ b/wxPython/src/helpers.cpp @@ -825,7 +825,6 @@ void wxPy_ReinitStockObjects(int pass) REINITOBJ(wxTheColourDatabase, wxColourDatabase); - REINITOBJ(wxTheClipboard, wxClipboard); REINITOBJ2(wxDefaultValidator, wxValidator); REINITOBJ2(wxNullImage, wxImage); REINITOBJ2(wxNullAcceleratorTable, wxAcceleratorTable); @@ -954,7 +953,7 @@ void wxPyPtrTypeMap_Add(const char* commonName, const char* ptrName) { -PyObject* wxPyMake_wxObject(wxObject* source, bool checkEvtHandler) { +PyObject* wxPyMake_wxObject(wxObject* source, bool setThisOwn, bool checkEvtHandler) { PyObject* target = NULL; bool isEvtHandler = False; @@ -987,7 +986,7 @@ PyObject* wxPyMake_wxObject(wxObject* source, bool checkEvtHandler) { exists = wxPyCheckSwigType(name); } if (info) { - target = wxPyConstructObject((void*)source, name, False); + target = wxPyConstructObject((void*)source, name, setThisOwn); if (target && isEvtHandler) ((wxEvtHandler*)source)->SetClientObject(new wxPyOORClientData(target)); } else { @@ -1004,7 +1003,7 @@ PyObject* wxPyMake_wxObject(wxObject* source, bool checkEvtHandler) { } -PyObject* wxPyMake_wxSizer(wxSizer* source) { +PyObject* wxPyMake_wxSizer(wxSizer* source, bool setThisOwn) { PyObject* target = NULL; if (source && wxIsKindOf(source, wxSizer)) { @@ -1019,7 +1018,7 @@ PyObject* wxPyMake_wxSizer(wxSizer* source) { } } if (! target) { - target = wxPyMake_wxObject(source, False); + target = wxPyMake_wxObject(source, setThisOwn, False); if (target != Py_None) ((wxSizer*)source)->SetClientObject(new wxPyOORClientData(target)); } @@ -1842,7 +1841,7 @@ PyObject* wxPy_ConvertList(wxListBase* listbase) { pyList = PyList_New(0); while (node) { wxObj = node->GetData(); - pyObj = wxPyMake_wxObject(wxObj); + pyObj = wxPyMake_wxObject(wxObj,false); PyList_Append(pyList, pyObj); node = node->GetNext(); }