diff options
author | David Edmundson <davidedmundson@kde.org> | 2020-04-19 15:14:02 +0100 |
---|---|---|
committer | David Edmundson <davidedmundson@kde.org> | 2020-08-26 16:11:46 +0100 |
commit | 16613f3741af013f7e380c98df6889d73512d0ad (patch) | |
tree | 8375963a816dfe50858ffbb5466797d9f7bc78bb /src/imports/layouts/qquicklayout.cpp | |
parent | 9aa152da3d416c7d5b4e0e970b6eb1a301df1028 (diff) |
Follow layoutMirroring in Layout margins
If a layout is laid out left to right using the layoutDirection
property, we want left Margins on the left, and rightMargin still on the
right
However, if a layout is mirrored, not only should the layout direction
change but also the left margin should now be on the right and vice
versa.
Task-number: QTBUG-62989
Pick-to: 5.15
Change-Id: Iaae4bc436fd1eb7f1947869563ac325f3d6b79bb
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
Diffstat (limited to 'src/imports/layouts/qquicklayout.cpp')
-rw-r--r-- | src/imports/layouts/qquicklayout.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/imports/layouts/qquicklayout.cpp b/src/imports/layouts/qquicklayout.cpp index 9e981f7de6..dbbd25de85 100644 --- a/src/imports/layouts/qquicklayout.cpp +++ b/src/imports/layouts/qquicklayout.cpp @@ -936,6 +936,11 @@ bool QQuickLayout::invalidatedArrangement() const return d_func()->m_dirtyArrangement; } +bool QQuickLayout::isMirrored() const +{ + return d_func()->isMirrored(); +} + void QQuickLayout::itemSiblingOrderChanged(QQuickItem *item) { Q_UNUSED(item); |