]> Creatis software - cpPlugins.git/blob - appli/PipelineEditor/PipelineEditor.h
...
[cpPlugins.git] / appli / PipelineEditor / PipelineEditor.h
1 #ifndef __PIPELINEEDITOR__H__
2 #define __PIPELINEEDITOR__H__
3
4 // Qt stuff
5 #include <QApplication>
6 #include <QMainWindow>
7 #include <cpPlugins/Interface.h>
8 #include <cpPlugins/Workspace.h>
9
10 /**
11  */
12 class PipelineEditor_Blocker
13   : public QObject
14 {
15 protected:
16   virtual bool eventFilter( QObject* obj, QEvent* event ) ITK_OVERRIDE;
17 };
18
19 // -------------------------------------------------------------------------
20 namespace Ui
21 {
22   class PipelineEditor;
23 }
24
25 /**
26  */
27 class PipelineEditor
28   : public QMainWindow
29 {
30   Q_OBJECT;
31
32 public:
33   typedef PipelineEditor Self;
34   typedef QMainWindow    Superclass;
35
36 public:
37   explicit PipelineEditor(
38     int argc, char* argv[],
39     QApplication* app,
40     QWidget* parent = NULL
41     );
42   virtual ~PipelineEditor( );
43
44 protected:
45   void _LoadPluginsFromPath( const std::string& path );
46   void _UpdateLoadedPlugins( );
47   void _Block( );
48   void _UnBlock( );
49
50 protected slots:
51   void _ButtonLoadPluginsFile( );
52   void _ButtonLoadPluginsPath( );
53   void _ActionOpenWorkspace( );
54   void _ActionSaveWorkspace( );
55   void _ExecFilter( const std::string& filter_name );
56   void _ShowFilterOutput(
57     const std::string& filter_name, const std::string& output_name
58     );
59
60 private:
61   Ui::PipelineEditor*    m_UI;
62   QApplication*          m_Application;
63   PipelineEditor_Blocker m_Blocker;
64   cpPlugins::Workspace*  m_Workspace;
65   cpPlugins::Interface   m_Interface;
66   std::string            m_PluginsPath;
67 };
68
69 #endif // __CPPIPELINEEDITOR__H__
70
71 // eof - $RCSfile$