diff options
author | J-P Nurmi <jpnurmi@qt.io> | 2018-04-23 11:42:37 +0200 |
---|---|---|
committer | J-P Nurmi <jpnurmi@qt.io> | 2018-04-23 15:49:31 +0000 |
commit | 7e3c882d9a5cd6a25f547091a4ece786f516f2a4 (patch) | |
tree | af93fed4a300b68933ceb749187649668c7d3976 /src/quicktemplates2/qquicktumbler.cpp | |
parent | 12e22e333d99d1a2fe9d878bb86108c87626e7ec (diff) |
Control: fix background size
Don't reset QQuickItemPrivate::widthValid and heightValid flags,
because that will cause the item to update its geometry when its
implicit size changes. Instead, keep track whether background has
an explicit size at the time of assignment, or if the background
changes its geometry outside of resizeBackground().
Task-number: QTBUG-66455
Change-Id: If14eeae6863f7e5e47ebf2d6dbdaf718fc8368d4
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Diffstat (limited to 'src/quicktemplates2/qquicktumbler.cpp')
-rw-r--r-- | src/quicktemplates2/qquicktumbler.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/quicktemplates2/qquicktumbler.cpp b/src/quicktemplates2/qquicktumbler.cpp index 4dc294e7..a40330a3 100644 --- a/src/quicktemplates2/qquicktumbler.cpp +++ b/src/quicktemplates2/qquicktumbler.cpp @@ -278,8 +278,9 @@ void QQuickTumblerPrivate::itemChildRemoved(QQuickItem *, QQuickItem *) _q_updateItemHeights(); } -void QQuickTumblerPrivate::itemGeometryChanged(QQuickItem *, QQuickGeometryChange change, const QRectF &) +void QQuickTumblerPrivate::itemGeometryChanged(QQuickItem *item, QQuickGeometryChange change, const QRectF &diff) { + QQuickControlPrivate::itemGeometryChanged(item, change, diff); if (change.sizeChange()) calculateDisplacements(); } |