On 06.01.08 21:13:44, Aaron Digulla wrote:
> The root cause is that setModel() doesn't increment the usage counter of
> the python class passed in, so Python will GC it if I don't save a
> pointer elsewhere.

Thats by purpose. One reason I can think of is that you often want to
use the model elsewhere to insert data or do something with the data and
then you often don't want a QAbstractItemModel instance but your
specific subclass.

Andreas

-- 
You should emulate your heros, but don't carry it too far.  Especially
if they are dead.
_______________________________________________
PyQt mailing list    PyQt@riverbankcomputing.com
http://www.riverbankcomputing.com/mailman/listinfo/pyqt

Reply via email to