py3: Gui: files P-Z ported to python3

This commit is contained in:
Yorik van Havre
2017-05-06 20:10:53 +02:00
committed by looooo
parent a3539c5168
commit 4f044dcbe4
4 changed files with 54 additions and 4 deletions

View File

@@ -1186,7 +1186,11 @@ PyObject *SelectionSingleton::sCountObjectsOfType(PyObject * /*self*/, PyObject
return NULL;
unsigned int count = Selection().countObjectsOfType(objecttype, document);
#if PY_MAJOR_VERSION < 3
return PyInt_FromLong(count);
#else
return PyLong_FromLong(count);
#endif
}
PyObject *SelectionSingleton::sGetSelection(PyObject * /*self*/, PyObject *args, PyObject * /*kwd*/)