- 10 Nov, 2015 1 commit
-
-
Craig Watson authored
Long version: UBGraphicsPolygonItem::shape() sometimes caused OpenBoard to crash due to inifinite recursion. This is easily replicated by trying to use the highlighting tool. The reason is: shape() calls boundingRect(); this function's definition is: QRectF QGraphicsPolygonItem::boundingRect() const { Q_D(const QGraphicsPolygonItem); if (d->boundingRect.isNull()) { qreal pw = pen().style() == Qt::NoPen ? qreal(0) : pen().widthF(); if (pw == 0.0) d->boundingRect = d->polygon.boundingRect(); else d->boundingRect = shape().controlPointRect(); } return d->boundingRect; } In the case where pw != 0, the shape() function is called. However, it is shape() from the derived class, not the base class, which is called. In other words, UBGraphicsPolygonItem::shape() is called rather than QGraphicsPolygonItem::shape(). This means that boundingRect() is called again from within shape(), and so on, causing the program to crash. The fix was simply to remove UBGraphicsPolygonItem::shape(), as it appears to provide the same (or very similar) functionality to that of the base class's shape() function. In case this shape() function actually is needed, another workaround should be implemented to prevent this infinite recursion.
-
- 14 Aug, 2013 1 commit
-
-
Claudio Valerio authored
-
- 04 Jun, 2013 1 commit
-
-
Ilia Ryabokon authored
-
- 29 Apr, 2013 2 commits
-
-
Claudio Valerio authored
-
Claudio Valerio authored
-
- 27 Feb, 2013 1 commit
-
-
Claudio Valerio authored
-
- 27 Sep, 2012 1 commit
-
-
Ilia Ryabokon authored
-
- 27 Aug, 2012 1 commit
-
-
Luca Capello authored
-
- 24 Aug, 2012 1 commit
-
-
Anatoly Mihalchenko authored
-
- 23 Aug, 2012 1 commit
-
-
Anatoly Mihalchenko authored
Interact with item bug with eraser
-
- 08 Aug, 2012 1 commit
-
-
Aleksei Kanash authored
Now coping creates a full copy of already created item. Copy has it's own content (like video, audio or folder) and stores original item properties (like locked, pos, size, freezed e.t.c.).
-
- 09 Jul, 2012 1 commit
-
-
Claudio Valerio authored
-
- 29 May, 2012 1 commit
-
-
Ilia Ryabokon authored
-
- 11 May, 2012 2 commits
-
-
Ivan Ilyin authored
-
Ivan Ilyin authored
-
- 09 May, 2012 1 commit
-
-
shibakaneki authored
-
- 02 May, 2012 1 commit
-
-
Ivan Ilyin authored
-
- 25 Apr, 2012 1 commit
-
-
Ivan Ilin authored
-
- 24 Apr, 2012 1 commit
-
-
shibakaneki authored
-
- 05 Apr, 2012 1 commit
-
-
shibakaneki authored
-
- 29 Mar, 2012 1 commit
-
-
Ivan Ilin authored
-
- 10 Nov, 2011 1 commit
-
-
Anatoly Mihalchenko authored
-
- 02 Aug, 2011 1 commit
-
-
Claudio Valerio authored
-
- 19 Apr, 2011 1 commit
-
-
Claudio Valerio authored
-