Fixed GetShapeList and similar methods to use OOR.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15106 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2002-04-11 23:12:02 +00:00
parent a22d737782
commit c893f25d86
12 changed files with 59 additions and 10 deletions

View File

@@ -186,6 +186,25 @@ PyObject* wxPyMake_wxShapeEvtHandler(wxShapeEvtHandler* source) {
return target;
}
//---------------------------------------------------------------------------
PyObject* wxPy_ConvertShapeList(wxListBase* list, const char* className) {
PyObject* pyList;
PyObject* pyObj;
wxObject* wxObj;
wxNode* node = list->First();
wxPyBeginBlockThreads();
pyList = PyList_New(0);
while (node) {
wxObj = node->Data();
pyObj = wxPyMake_wxShapeEvtHandler((wxShapeEvtHandler*)wxObj);
PyList_Append(pyList, pyObj);
node = node->Next();
}
wxPyEndBlockThreads();
return pyList;
}
//---------------------------------------------------------------------------