Cannot delete when the rect has no scene..
parent
d9c574e291
commit
88f415e5b8
|
@ -599,6 +599,9 @@ class SelectRect(QtWidgets.QGraphicsRectItem):
|
||||||
|
|
||||||
'''
|
'''
|
||||||
scen: QGraphicsScene = self.scene()
|
scen: QGraphicsScene = self.scene()
|
||||||
|
if scen is None:
|
||||||
|
return
|
||||||
|
|
||||||
scen.removeItem(self)
|
scen.removeItem(self)
|
||||||
if (
|
if (
|
||||||
self._label
|
self._label
|
||||||
|
|
Loading…
Reference in New Issue