[vlmc-devel] GraphicsCursorItem: Specify a specific item type for this kind of item

Hugo Beauzée-Luyssen git at videolan.org
Thu Feb 24 16:44:28 CET 2011


vlmc | branch: master | Hugo Beauzée-Luyssen <beauze.h at gmail.com> | Sun Feb  6 19:57:39 2011 +0100| [7445ac8362e8b975ca3114de01b54cd19a5e477c] | committer: Hugo Beauzée-Luyssen

GraphicsCursorItem: Specify a specific item type for this kind of item

> http://git.videolan.org/gitweb.cgi/vlmc.git/?a=commit;h=7445ac8362e8b975ca3114de01b54cd19a5e477c
---

 src/Gui/timeline/GraphicsCursorItem.h |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/src/Gui/timeline/GraphicsCursorItem.h b/src/Gui/timeline/GraphicsCursorItem.h
index e80180c..0089b2a 100644
--- a/src/Gui/timeline/GraphicsCursorItem.h
+++ b/src/Gui/timeline/GraphicsCursorItem.h
@@ -37,6 +37,8 @@ class GraphicsCursorItem : public QObject, public QGraphicsItem
 {
     Q_OBJECT
 
+    enum { Type = UserType + 5 };
+
 #if QT_VERSION >= 0x40600
     Q_INTERFACES( QGraphicsItem )
 #endif
@@ -46,6 +48,7 @@ public:
     int                 cursorPos() const { return ( int )pos().x(); }
     virtual QRectF      boundingRect() const;
     void                setHeight( int height );
+    virtual int         type() const { return Type; }
 
 protected:
     virtual void        paint( QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget = 0 );



More information about the Vlmc-devel mailing list