From: Robin Dunn Date: Mon, 2 Apr 2001 07:33:47 +0000 (+0000) Subject: Fixed Tim's patch so it will compile when using a Python version < 2.0 X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/a7fa65b96e0076675dbc6d34a7849a20e67946a0?ds=sidebyside Fixed Tim's patch so it will compile when using a Python version < 2.0 git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@9641 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/wxPython/src/helpers.cpp b/wxPython/src/helpers.cpp index 3aa1ae21d9..9d12d8962a 100644 --- a/wxPython/src/helpers.cpp +++ b/wxPython/src/helpers.cpp @@ -784,6 +784,11 @@ static inline bool wxPointFromObjects(PyObject* o1, PyObject* o2, wxPoint* point } +#if PYTHON_API_VERSION < 1009 +#define PySequence_Fast_GET_ITEM(o, i)\ + (PyList_Check(o) ? PyList_GET_ITEM(o, i) : PyTuple_GET_ITEM(o, i)) +#endif + wxPoint* wxPoint_LIST_helper(PyObject* source, int *count) { // Putting all of the declarations here allows // us to put the error handling all in one place.