summaryrefslogtreecommitdiffstats
path: root/src/gui/graphicsview
diff options
context:
space:
mode:
authorKent Hansen <khansen@trolltech.com>2009-05-22 11:11:41 (GMT)
committerKent Hansen <khansen@trolltech.com>2009-05-22 11:11:41 (GMT)
commit1a709fbe25a2446a9b311ded88aec5565258f3ac (patch)
tree0c7b0a5fbd94b7a4d59666f671fc8f995153161b /src/gui/graphicsview
parent5a734e4657161e0877b32181df35a56241b21de4 (diff)
downloadQt-1a709fbe25a2446a9b311ded88aec5565258f3ac.zip
Qt-1a709fbe25a2446a9b311ded88aec5565258f3ac.tar.gz
Qt-1a709fbe25a2446a9b311ded88aec5565258f3ac.tar.bz2
Say hello to animation API & state machine API
Diffstat (limited to 'src/gui/graphicsview')
-rw-r--r--src/gui/graphicsview/qgraphicsitem_p.h12
-rw-r--r--src/gui/graphicsview/qgraphicsproxywidget.cpp2
-rw-r--r--src/gui/graphicsview/qgraphicsproxywidget.h2
3 files changed, 15 insertions, 1 deletions
diff --git a/src/gui/graphicsview/qgraphicsitem_p.h b/src/gui/graphicsview/qgraphicsitem_p.h
index b2569c1..62e0411 100644
--- a/src/gui/graphicsview/qgraphicsitem_p.h
+++ b/src/gui/graphicsview/qgraphicsitem_p.h
@@ -95,6 +95,15 @@ class Q_AUTOTEST_EXPORT QGraphicsItemPrivate
{
Q_DECLARE_PUBLIC(QGraphicsItem)
public:
+ struct TransformData
+ {
+ TransformData() : rotationX(0),rotationY(0),rotationZ(0),scaleX(1),scaleY(1), dirty(true) {}
+ QTransform baseTransform;
+ QTransform transform;
+ QPointF transformCenter;
+ qreal rotationX,rotationY,rotationZ,scaleX,scaleY;
+ bool dirty;
+ };
enum Extra {
ExtraTransform,
ExtraToolTip,
@@ -239,7 +248,7 @@ public:
}
}
}
-
+
struct ExtraStruct {
ExtraStruct(Extra type, QVariant value)
: type(type), value(value)
@@ -251,6 +260,7 @@ public:
bool operator<(Extra extra) const
{ return type < extra; }
};
+
QList<ExtraStruct> extras;
QGraphicsItemCache *maybeExtraItemCache() const;
diff --git a/src/gui/graphicsview/qgraphicsproxywidget.cpp b/src/gui/graphicsview/qgraphicsproxywidget.cpp
index 01b7593..a5b11ff 100644
--- a/src/gui/graphicsview/qgraphicsproxywidget.cpp
+++ b/src/gui/graphicsview/qgraphicsproxywidget.cpp
@@ -976,6 +976,7 @@ void QGraphicsProxyWidget::contextMenuEvent(QGraphicsSceneContextMenuEvent *even
}
#endif // QT_NO_CONTEXTMENU
+#ifndef QT_NO_DRAGANDDROP
/*!
\reimp
*/
@@ -1096,6 +1097,7 @@ void QGraphicsProxyWidget::dropEvent(QGraphicsSceneDragDropEvent *event)
}
#endif
}
+#endif
/*!
\reimp
diff --git a/src/gui/graphicsview/qgraphicsproxywidget.h b/src/gui/graphicsview/qgraphicsproxywidget.h
index b2c3c8f..ab8c9da 100644
--- a/src/gui/graphicsview/qgraphicsproxywidget.h
+++ b/src/gui/graphicsview/qgraphicsproxywidget.h
@@ -90,10 +90,12 @@ protected:
void contextMenuEvent(QGraphicsSceneContextMenuEvent *event);
#endif
+#ifndef QT_NO_DRAGANDDROP
void dragEnterEvent(QGraphicsSceneDragDropEvent *event);
void dragLeaveEvent(QGraphicsSceneDragDropEvent *event);
void dragMoveEvent(QGraphicsSceneDragDropEvent *event);
void dropEvent(QGraphicsSceneDragDropEvent *event);
+#endif
void hoverEnterEvent(QGraphicsSceneHoverEvent *event);
void hoverLeaveEvent(QGraphicsSceneHoverEvent *event);