X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/4519a2d9113d2ea6c17d3cee54a6e0ed354521f8..c437fde9f90fc7dfcac79053d214fc9146d7be21:/wxPython/src/drawlist.cpp diff --git a/wxPython/src/drawlist.cpp b/wxPython/src/drawlist.cpp index 0c7cd62fe8..c89342ac84 100644 --- a/wxPython/src/drawlist.cpp +++ b/wxPython/src/drawlist.cpp @@ -30,7 +30,7 @@ void wxPyDrawList_SetAPIPtr() PyObject* wxPyDrawXXXList(wxDC& dc, wxPyDrawListOp_t doDraw, PyObject* pyCoords, PyObject* pyPens, PyObject* pyBrushes) { - bool blocked = wxPyBeginBlockThreads(); + wxPyBlock_t blocked = wxPyBeginBlockThreads(); bool isFastSeq = PyList_Check(pyCoords) || PyTuple_Check(pyCoords); bool isFastPens = PyList_Check(pyPens) || PyTuple_Check(pyPens); @@ -215,7 +215,7 @@ bool wxPyDrawXXXPolygon(wxDC& dc, PyObject* coords) PyObject* wxPyDrawTextList(wxDC& dc, PyObject* textList, PyObject* pyPoints, PyObject* foregroundList, PyObject* backgroundList) { - bool blocked = wxPyBeginBlockThreads(); + wxPyBlock_t blocked = wxPyBeginBlockThreads(); bool isFastSeq = PyList_Check(pyPoints) || PyTuple_Check(pyPoints); bool isFastText = PyList_Check(textList) || PyTuple_Check(textList); @@ -258,7 +258,7 @@ PyObject* wxPyDrawTextList(wxDC& dc, PyObject* textList, PyObject* pyPoints, PyO else { obj = PySequence_GetItem(textList, i); } - if (! PyString_Check(obj) ) { + if (! PyString_Check(obj) && !PyUnicode_Check(obj) ) { Py_DECREF(obj); goto err1; }