diff options
author | Caio Marcelo de Oliveira Filho <caio.oliveira@openbossa.org> | 2009-09-25 22:35:25 (GMT) |
---|---|---|
committer | Jan-Arve Sæther <jan-arve.saether@nokia.com> | 2009-10-06 09:28:53 (GMT) |
commit | 0536b996759ef367e784310f472089eec583213f (patch) | |
tree | 3e858c6c65ff63ff6d5486c6dbc8d95b50171e23 /src/gui/graphicsview/qgraphicsanchorlayout_p.h | |
parent | ba66cc0bde91e1143ac0a34f249f98e4573a5737 (diff) | |
download | Qt-0536b996759ef367e784310f472089eec583213f.zip Qt-0536b996759ef367e784310f472089eec583213f.tar.gz Qt-0536b996759ef367e784310f472089eec583213f.tar.bz2 |
QGraphicsAnchorLayout: Add support for expanding SizePolicy with simplification
Updating "refreshSizeHints" and "updateChildrenSizes" methods for standard,
parallel and sequential anchors, in order to support the expanding SizePolicy
flag.
This adds the logic required to calculate equivalent expected/nominal expanding
size (AnchorData::expSize) as well as the logic to propagate the effective
size when in the expanding state (AnchorData::sizeAtExpected).
Signed-off-by: Caio Marcelo de Oliveira Filho <caio.oliveira@openbossa.org>
Reviewed-by: Eduardo M. Fleury <eduardo.fleury@openbossa.org>
Diffstat (limited to 'src/gui/graphicsview/qgraphicsanchorlayout_p.h')
-rw-r--r-- | src/gui/graphicsview/qgraphicsanchorlayout_p.h | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/gui/graphicsview/qgraphicsanchorlayout_p.h b/src/gui/graphicsview/qgraphicsanchorlayout_p.h index 8f67b2c..aac4f96 100644 --- a/src/gui/graphicsview/qgraphicsanchorlayout_p.h +++ b/src/gui/graphicsview/qgraphicsanchorlayout_p.h @@ -156,8 +156,7 @@ struct AnchorData : public QSimplexVariable { sizeAtMinimum(0), sizeAtPreferred(0), sizeAtExpanding(0), sizeAtMaximum(0), graphicsAnchor(0), skipInPreferred(0), - type(Normal), hasSize(true), isLayoutAnchor(false), - isExpanding(false) {} + type(Normal), hasSize(true), isLayoutAnchor(false) {} virtual void updateChildrenSizes() {} virtual void refreshSizeHints(qreal effectiveSpacing); @@ -214,7 +213,6 @@ struct AnchorData : public QSimplexVariable { uint type : 2; // either Normal, Sequential or Parallel uint hasSize : 1; // if false, get size from style. uint isLayoutAnchor : 1; // if this anchor is connected to a layout 'edge' - uint isExpanding : 1; // if true, expands before other anchors }; #ifdef QT_DEBUG |