]> SALOME platform Git repositories - modules/visu.git/blob - src/VISUGUI/VisuGUI_ViewExtender.h
Salome HOME
Update translations
[modules/visu.git] / src / VISUGUI / VisuGUI_ViewExtender.h
1 // Copyright (C) 2007-2011  CEA/DEN, EDF R&D, OPEN CASCADE
2 //
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License.
7 //
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
11 // Lesser General Public License for more details.
12 //
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
16 //
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 //
19
20 //  VISU VISUGUI : GUI of VISU component
21 //  File   : VisuGUI_ViewExtender.h
22 //  Author : Vitaly Smetannikov
23 //  Module : VISU
24 //
25 #ifndef VisuGUI_ViewExtender_HeaderFile
26 #define VisuGUI_ViewExtender_HeaderFile
27
28 #include <CAM_ViewExtender.h>
29 #include <SALOME_ListIO.hxx>
30 #include <QObject>
31 #include <QMap>
32
33 class VisuGUI;
34 //class QtxAction;
35 //class QDialog;
36
37 class VisuGUI_SegmentationMgr;
38 class SVTK_Viewer;
39 class SVTK_ViewWindow;
40 class SUIT_ViewWindow;
41 class VTKViewer_Actor;
42
43
44 class VisuGUI_ViewExtender:  public QObject, public CAM_ViewExtender
45 {
46   Q_OBJECT
47
48  public:
49   VisuGUI_ViewExtender(VisuGUI* theModule);
50
51   virtual ~VisuGUI_ViewExtender();
52
53   virtual int createToolbar(SUIT_ViewWindow* theView);
54   virtual void contextMenuPopup(QMenu* theMenu);
55
56   virtual void activate(SUIT_ViewModel*);
57   virtual void deactivate(SUIT_ViewModel*);
58
59   VisuGUI_SegmentationMgr* getSegmentationMgr(SVTK_ViewWindow* theWindow);
60  
61
62 private slots:
63   //  void onPlanesMgr();
64   // void onDialogDestroy(); 
65   // void onShowPlanes(bool);
66   // void onDeactivatePlanes(bool);
67  void onViewDeleted(SUIT_ViewWindow* theWindow);
68  void onAddActor(SVTK_ViewWindow* theWindow, VTKViewer_Actor* theActor);
69
70  private:
71
72  //enum { ClippingPlaneMgrId, ShowClippingPlanesId, DeactivateClippingPlanesId };
73
74  //QMap<int, QtxAction*> myActionsMap;
75   VisuGUI* myModule;
76
77   //QDialog* myNonModalDlg;
78
79   //VisuGUI_SegmentationMgr* mySegmentationMgr;
80   QMap<SVTK_ViewWindow*, VisuGUI_SegmentationMgr*> myViewMgrMap;
81
82   QList<SVTK_Viewer*> myViewers;
83
84   //SALOME_ListIO myListIO;
85   
86 };
87
88
89 #endif