[Kde-bindings] Containers passed by reference
David Palacio
dpalacio at uninorte.edu.co
Fri Dec 12 12:23:12 UTC 2008
This is similar to the QImage::bits one. In the Okular bindings a QVector is
marshalled to a Ruby array but the original QVector is never updated. This is
not the expected behaviour by Okular.
virtual bool loadDocument (const QString &fileName, QVector< Page * >
&pagesVector)=0
is the c++ signature of a method that needs to be implemented in a generator.
pagesVector is a QVector& that will be updated inside this method.
I have confirmed, on the C++ side, that the pagesVector has zero size.
This would need a special case: create a Ruby Array outside the method and
pass it as an argument. When the method finishes, update the QVector.
More information about the Kde-bindings
mailing list