]> Creatis software - cpPlugins.git/blob - appli/cpPipelineEditor/QNodesEditorCanvas.h
More on graph editor
[cpPlugins.git] / appli / cpPipelineEditor / QNodesEditorCanvas.h
1 #ifndef __PIPELINEEDITOR__QNODESEDITORCANVAS__H__
2 #define __PIPELINEEDITOR__QNODESEDITORCANVAS__H__
3
4 #include <QtGui/QGraphicsView>
5
6 namespace PipelineEditor
7 {
8   // Some other forward declarations
9   class QNEBlock;
10   class QNEConnection;
11   class QNodesEditor;
12
13   /**
14    */
15   class QNodesEditorCanvas
16     : public QGraphicsView
17   {
18     Q_OBJECT;
19
20   public:
21     QNodesEditorCanvas( QWidget* parent = 0 );
22     virtual ~QNodesEditorCanvas( );
23
24     QNodesEditor* editor( );
25     const QNodesEditor* editor( ) const;
26
27   protected:
28     /* TODO
29        void keyPressEvent( QKeyEvent* event );
30        void timerEvent( QTimerEvent* event );
31     */
32     void wheelEvent( QWheelEvent* event );
33
34     void dragEnterEvent( QDragEnterEvent* event );
35     void dragLeaveEvent( QDragLeaveEvent* event );
36     void dragMoveEvent( QDragMoveEvent* event );
37     void dropEvent( QDropEvent* event );
38
39     void _scaleView( qreal scaleFactor );
40
41   protected:
42     QNodesEditor* m_Editor;
43   };
44
45 } // ecapseman
46
47 #endif // __PIPELINEEDITOR__QNODESEDITORCANVAS__H__
48
49 // eof - $RCSfile$