Details
-
Bug
-
Resolution: Unresolved
-
P1: Critical
-
None
-
5.15.2
-
None
Description
QGraphicsItem sends events before it is finally constructed!
Procedure to reproduce crash:
- Run QtCreator (from within QtCreator debugger to see call stack)
- Create a new (scratch) model
- Drag a "Boundary" element onto diagram
- Enlarge boundary
- Click into label field and enter some letters
- Without leaving the label field (do not click outside), drag another "Item" element into the boundary.
- QtCreator crashs!
The call stack shows a __cxa_pure_virtual call after calling QGraphicsItem::childrenBoundingRect() from within qmt::ObjectItem::boundingRect(). If you look further up the call stack you find a call to the constructor QGraphicsRectItem::QGraphicsRectItem(QGraphicsItem*). In between you see some handling of a FocusIn event. It looks like this event is sent before the QGraphicsRectItem() is finally constructed and some methods are still pure virtual.