diff options
author | Water-Team <water@pad.test.qt.nokia.com> | 2011-11-16 00:00:13 (GMT) |
---|---|---|
committer | Water-Team <water@pad.test.qt.nokia.com> | 2011-11-16 00:00:13 (GMT) |
commit | f992096a065c99f8307965f73e29ebad49ee6b9b (patch) | |
tree | cc31ebf4d7a04e533eb9340114db14cc10e42b58 /src/gui/graphicsview | |
parent | 301ec400cf5257d0ce5aec7ac4a9e7a0edf77ca3 (diff) | |
parent | 19f53dd23c29d9a6b256ea1473b118abcde3cc5a (diff) | |
download | Qt-f992096a065c99f8307965f73e29ebad49ee6b9b.zip Qt-f992096a065c99f8307965f73e29ebad49ee6b9b.tar.gz Qt-f992096a065c99f8307965f73e29ebad49ee6b9b.tar.bz2 |
Merge branch '4.8-upstream' into master-water
Diffstat (limited to 'src/gui/graphicsview')
-rw-r--r-- | src/gui/graphicsview/qgraphicsitem.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gui/graphicsview/qgraphicsitem.cpp b/src/gui/graphicsview/qgraphicsitem.cpp index 73e8eed..9ea0b83 100644 --- a/src/gui/graphicsview/qgraphicsitem.cpp +++ b/src/gui/graphicsview/qgraphicsitem.cpp @@ -1157,7 +1157,6 @@ void QGraphicsItemPrivate::setParentItemHelper(QGraphicsItem *newParent, const Q if (q_ptr == fsi || q_ptr->isAncestorOf(fsi)) { parentFocusScopeItem = fsi; p->d_ptr->focusScopeItem = 0; - fsi->d_ptr->focusScopeItemChange(false); } break; } @@ -1261,6 +1260,10 @@ void QGraphicsItemPrivate::setParentItemHelper(QGraphicsItem *newParent, const Q if (!inDestructor && (transformData || (newParent && newParent->d_ptr->transformData))) transformChanged(); + // Reparenting is finished, now safe to notify the previous focusScopeItem about changes + if (parentFocusScopeItem) + parentFocusScopeItem->d_ptr->focusScopeItemChange(false); + // Restore the sub focus chain. if (subFocusItem) { subFocusItem->d_ptr->setSubFocus(newParent); |