summaryrefslogtreecommitdiffstats
path: root/src/declarative
diff options
context:
space:
mode:
authorMartin Jones <martin.jones@nokia.com>2010-06-17 06:37:38 (GMT)
committerMartin Jones <martin.jones@nokia.com>2010-06-17 06:37:38 (GMT)
commitd2c04d76fc26300a33842a2ef52613f189a07c3c (patch)
tree841c2bd8a452a3209dd1d40e0d53f26a2f6674ca /src/declarative
parentf8080432e1307c099aee65153870af7c1677ccba (diff)
parentcc621ba462331ad936f47c44c22030392caa574f (diff)
downloadQt-d2c04d76fc26300a33842a2ef52613f189a07c3c.zip
Qt-d2c04d76fc26300a33842a2ef52613f189a07c3c.tar.gz
Qt-d2c04d76fc26300a33842a2ef52613f189a07c3c.tar.bz2
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-qml into 4.7
Diffstat (limited to 'src/declarative')
-rw-r--r--src/declarative/graphicsitems/qdeclarativeitem.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/declarative/graphicsitems/qdeclarativeitem.cpp b/src/declarative/graphicsitems/qdeclarativeitem.cpp
index 42b370b..336010f 100644
--- a/src/declarative/graphicsitems/qdeclarativeitem.cpp
+++ b/src/declarative/graphicsitems/qdeclarativeitem.cpp
@@ -345,10 +345,11 @@ void QDeclarativeContents::complete()
void QDeclarativeContents::itemGeometryChanged(QDeclarativeItem *changed, const QRectF &newGeometry, const QRectF &oldGeometry)
{
- if (newGeometry.width() != oldGeometry.width())
- calcWidth(changed);
- if (newGeometry.height() != oldGeometry.height())
- calcHeight(changed);
+ //### we can only pass changed if the left edge has moved left, or the right edge has moved right
+ if (newGeometry.width() != oldGeometry.width() || newGeometry.x() != oldGeometry.x())
+ calcWidth(/*changed*/);
+ if (newGeometry.height() != oldGeometry.height() || newGeometry.y() != oldGeometry.y())
+ calcHeight(/*changed*/);
}
void QDeclarativeContents::itemDestroyed(QDeclarativeItem *item)