[PyKDE] ANN: New Releases of PyQt, PyKDE, SIP and QScintilla
Phil Thompson
phil at riverbankcomputing.co.uk
Mon Sep 5 08:30:14 BST 2005
> On Sunday 04 September 2005 22:49, Phil Thompson wrote:
>> On Sunday 04 September 2005 9:02 pm, David Boddie wrote:
>
>> > I thought this just meant that the C++ wrapper stays around, but the
>> > Python implementation is still collected. My plugin's __del__ method
>> is
>> > still called, just as before.
>>
>> No - the C++ instance (not the wrapper) stays around.
>
> OK, then I'll still need to keep a reference to the plugin from somewhere
> in Python. The pure C++ instance won't do anything useful without its
> Python counterpart.
Just to clarify - the second argument to sip.transferto() being None means
that the wrapper gets garbage collected. If you pass a wrapped object
instead then that wrapped object is given a reference to the object passed
as the first argument and so wouldn't be garbage collected (unless
detected as part of a cycle).
Phil
More information about the PyQt
mailing list