Hi,<br>I&#39;m using the newest version of Qt and PyQt. I have my own subclass of QGraphicsItem and it happens that I get the same reference when creating two instances.<br><br>I suppose the subclass is implemented properly, here is the beginning which is the most crucial part:
<br>class Circle(QtGui.QGraphicsItem):<br>&nbsp;&nbsp;&nbsp; def __init__(self, radius, items, parent):<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; QtGui.QGraphicsItem.__init__(self, parent)<br><br>It seems that I get the reference to the same object. I check It with print(&#39;circle &#39;+str(circle)):
<br><br>new circle &lt;items.Circle object at 0x00C0CF18&gt;<br>circle shutdown &lt;items.Circle object at 0x00C0CF18&gt;<br>new circle &lt;items.Circle object at 0x00C0CF18&gt;<br><br>and the line responsible for creating the item is as follows:
<br>c = Circle(self._nextRadius(item.getMenuItems()), item.getMenuItems(), self)<br><br>How is this possible?<br><br>Have to mention that with the same implementation I didn&#39;t have that problem using older version of Qt + PyQt.
<br><br>Best Regards,<br>Krystian<br>