+ Make Python API more pythonic

This commit is contained in:
wmayer
2013-10-11 13:57:05 +02:00
parent c245407327
commit ad877e1ae1
20 changed files with 255 additions and 256 deletions

View File

@@ -462,10 +462,10 @@ PyObject *PropertyFilletEdges::getPyObject(void)
void PropertyFilletEdges::setPyObject(PyObject *value)
{
Py::List list(value);
Py::Sequence list(value);
std::vector<FilletElement> values;
values.reserve(list.size());
for (Py::List::iterator it = list.begin(); it != list.end(); ++it) {
for (Py::Sequence::iterator it = list.begin(); it != list.end(); ++it) {
FilletElement fe;
Py::Tuple ent(*it);
fe.edgeid = (int)Py::Int(ent.getItem(0));