diff options
author | Olivier Goffart <ogoffart@trolltech.com> | 2009-05-20 14:38:47 (GMT) |
---|---|---|
committer | Andreas Aardal Hanssen <andreas.aardal.hanssen@nokia.com> | 2009-06-09 07:43:22 (GMT) |
commit | 56f23d4ccfc27f737d30e92ae5b3ecde6e8b0bbf (patch) | |
tree | cd4b34938a2f52ab7734496ac4a79089a1343ddf /src/gui/graphicsview/qgraphicsscene.cpp | |
parent | 9ed567ca68d51552f89887aa5a300a5f6a6d8ac3 (diff) | |
download | Qt-56f23d4ccfc27f737d30e92ae5b3ecde6e8b0bbf.zip Qt-56f23d4ccfc27f737d30e92ae5b3ecde6e8b0bbf.tar.gz Qt-56f23d4ccfc27f737d30e92ae5b3ecde6e8b0bbf.tar.bz2 |
Add (back) properties to QGraphicsItem to change the transformations component
This reapply commit 8ad5020940f10d4ecc5c5e8b3b9656531cb84ef3 and its
dependent change that has been reverted while rebasing the
recursivepaint branch.
With the new properties it is possible to easily animate transformations
Reviewed-by: Andreas
Documentation still need to be reviewed.
Diffstat (limited to 'src/gui/graphicsview/qgraphicsscene.cpp')
-rw-r--r-- | src/gui/graphicsview/qgraphicsscene.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/gui/graphicsview/qgraphicsscene.cpp b/src/gui/graphicsview/qgraphicsscene.cpp index ad392b0..1014550 100644 --- a/src/gui/graphicsview/qgraphicsscene.cpp +++ b/src/gui/graphicsview/qgraphicsscene.cpp @@ -1737,7 +1737,7 @@ void QGraphicsScenePrivate::childItems_helper(QList<QGraphicsItem *> *items, QList<QGraphicsItem *> &children = parent->d_ptr->children; for (int i = 0; i < children.size(); ++i) { QGraphicsItem *item = children.at(i); - if (item->d_ptr->transform && !item->d_ptr->transform->isInvertible()) + if (item->d_ptr->transformData && !item->d_ptr->transformData->computedFullTransform().isInvertible()) continue; // Skip invisible items and all their children. @@ -1777,7 +1777,7 @@ void QGraphicsScenePrivate::childItems_helper(QList<QGraphicsItem *> *items, QList<QGraphicsItem *> &children = parent->d_ptr->children; for (int i = 0; i < children.size(); ++i) { QGraphicsItem *item = children.at(i); - if (item->d_ptr->transform && !item->d_ptr->transform->isInvertible()) + if (item->d_ptr->transformData && !item->d_ptr->transformData->computedFullTransform().isInvertible()) continue; // Skip invisible items and all their children. @@ -1813,7 +1813,7 @@ void QGraphicsScenePrivate::childItems_helper(QList<QGraphicsItem *> *items, if ((keep || !(item->flags() & QGraphicsItem::ItemClipsChildrenToShape)) && !item->d_ptr->children.isEmpty()) { // Recurse into children. - if (!item->d_ptr->transform || item->d_ptr->transform->type() <= QTransform::TxScale) { + if (!item->d_ptr->transformData || item->d_ptr->transformData->computedFullTransform().type() <= QTransform::TxScale) { // Rect childItems_helper(items, item, item->mapRectFromParent(rect), mode); } else { @@ -1843,7 +1843,7 @@ void QGraphicsScenePrivate::childItems_helper(QList<QGraphicsItem *> *items, QList<QGraphicsItem *> &children = parent->d_ptr->children; for (int i = 0; i < children.size(); ++i) { QGraphicsItem *item = children.at(i); - if (item->d_ptr->transform && !item->d_ptr->transform->isInvertible()) + if (item->d_ptr->transformData && !item->d_ptr->transformData->computedFullTransform().isInvertible()) continue; // Skip invisible items. @@ -1902,7 +1902,7 @@ void QGraphicsScenePrivate::childItems_helper(QList<QGraphicsItem *> *items, QList<QGraphicsItem *> &children = parent->d_ptr->children; for (int i = 0; i < children.size(); ++i) { QGraphicsItem *item = children.at(i); - if (item->d_ptr->transform && !item->d_ptr->transform->isInvertible()) + if (item->d_ptr->transformData && !item->d_ptr->transformData->computedFullTransform().isInvertible()) continue; // Skip invisible items. |