diff options
| author | Fabian Kosmale <fabian.kosmale@qt.io> | 2025-12-17 10:23:23 +0100 |
|---|---|---|
| committer | Shawn Rutledge <shawn.rutledge@qt.io> | 2025-12-19 10:46:06 +0100 |
| commit | 5e7b5ba024c243910b0931ee83175408024ce80c (patch) | |
| tree | e5718fd893c47d77746f6a5e42cb12186380891f | |
| parent | 0364a73c65629412e8b3959692e7cd405894099a (diff) | |
QQuickItem::clipRect: Don't participate in bindings
We don't want clipRect to capture width and height. While technically
that would make sense (after all, the clipRect does change if you modify
width and height), it makes internal usage of the function problematic:
We could end up creating binding loops if it's triggered by the width or
height setter (which is the case with an upcoming change to
transformChanged).
Pick-to: 6.11
Change-Id: I3e19a9687a025e35969d16f300ca2d1b6fc8a624
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| -rw-r--r-- | src/quick/items/qquickitem.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/quick/items/qquickitem.cpp b/src/quick/items/qquickitem.cpp index 0558495332..be89a90bdf 100644 --- a/src/quick/items/qquickitem.cpp +++ b/src/quick/items/qquickitem.cpp @@ -5955,7 +5955,7 @@ QRectF QQuickItem::boundingRect() const QRectF QQuickItem::clipRect() const { Q_D(const QQuickItem); - QRectF ret(0, 0, d->width, d->height); + QRectF ret(0, 0, d->width.valueBypassingBindings(), d->height.valueBypassingBindings()); if (flags().testFlag(QQuickItem::ItemObservesViewport)) { if (QQuickItem *viewport = viewportItem()) { // if the viewport is already "this", there's nothing to intersect; |
