summaryrefslogtreecommitdiffstats
path: root/src/gui/graphicsview
diff options
context:
space:
mode:
authorWater-Team <water@pad.test.qt.nokia.com>2011-11-16 00:00:13 (GMT)
committerWater-Team <water@pad.test.qt.nokia.com>2011-11-16 00:00:13 (GMT)
commitf992096a065c99f8307965f73e29ebad49ee6b9b (patch)
treecc31ebf4d7a04e533eb9340114db14cc10e42b58 /src/gui/graphicsview
parent301ec400cf5257d0ce5aec7ac4a9e7a0edf77ca3 (diff)
parent19f53dd23c29d9a6b256ea1473b118abcde3cc5a (diff)
downloadQt-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.cpp5
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);