Fixed custom code for QScriptValueIterator.__next__ function.

It must not use the convenience method Shiboken::makeTuple, for it makes
use of the old template based converters.
This commit is contained in:
Marcelo Lira 2011-11-30 16:00:57 -03:00 • committed by Hugo Parente Lima
commit 770c8bda73

View file

@ -100,7 +100,11 @@
<inject-code> <inject-code>
if (%CPPSELF.hasNext()) { if (%CPPSELF.hasNext()) {
%CPPSELF.next(); %CPPSELF.next();
%PYARG_0 = Shiboken::makeTuple(%CPPSELF.name(), %CPPSELF.value().toVariant()); QString name = %CPPSELF.name();
QVariant value = %CPPSELF.value().toVariant();
%PYARG_0 = PyTuple_New(2);
PyTuple_SET_ITEM(%PYARG_0, 0, %CONVERTTOPYTHON[QString](name));
PyTuple_SET_ITEM(%PYARG_0, 1, %CONVERTTOPYTHON[QVariant](value));
} else { } else {
PyErr_SetNone(PyExc_StopIteration); PyErr_SetNone(PyExc_StopIteration);
} }