diff options
author | Fabian Kosmale <fabian.kosmale@qt.io> | 2021-06-29 12:08:42 +0200 |
---|---|---|
committer | Fabian Kosmale <fabian.kosmale@qt.io> | 2021-06-30 10:08:03 +0200 |
commit | f3452af843fbb50718d60dc4b2726bc156b2b44c (patch) | |
tree | d09a5667dece1cc86a37a165a83cc5d9add10728 /src/quick/items/qquickitem_p.h | |
parent | 6616008e2e3de940bcd551ad2832ebfed2b9e063 (diff) |
QQuickItemPrivate: Make {width,height}Valid a function
There is now some additional logic, so we cannot simply rely on the
boolean flag.
Task-number: QTBUG-94703
Pick-to: 6.2
Change-Id: Id4674efd205a58b015a82b3c06e63c8a031f6607
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Diffstat (limited to 'src/quick/items/qquickitem_p.h')
-rw-r--r-- | src/quick/items/qquickitem_p.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/quick/items/qquickitem_p.h b/src/quick/items/qquickitem_p.h index de6bb4aedd..3004fcd70d 100644 --- a/src/quick/items/qquickitem_p.h +++ b/src/quick/items/qquickitem_p.h @@ -441,8 +441,8 @@ public: // Bit 0 quint32 flags:5; - bool widthValid:1; - bool heightValid:1; + bool widthValidFlag:1; + bool heightValidFlag:1; bool componentComplete:1; bool keepMouse:1; bool keepTouch:1; @@ -578,6 +578,9 @@ public: qreal implicitWidth; qreal implicitHeight; + bool widthValid() const { return widthValidFlag || width.hasBinding(); } + bool heightValid() const { return heightValidFlag || height.hasBinding(); } + qreal baselineOffset; QList<QQuickTransform *> transforms; |