Commit 59a4a908 authored by Vlad Zahorodnii's avatar Vlad Zahorodnii
Browse files

Properly update parent item's bounding rect when moving item

The bounding rect of an item is in the item-local coordinate space. If
the item is moved, its bounding rect won't change, but the parent's
bounding rect, may change.

BUG: 443756
parent ff3465a8
......@@ -106,7 +106,9 @@ void Item::setPosition(const QPoint &point)
if (m_position != point) {
scheduleRepaint(boundingRect());
m_position = point;
updateBoundingRect();
if (m_parentItem) {
m_parentItem->updateBoundingRect();
}
scheduleRepaint(boundingRect());
Q_EMIT positionChanged();
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment