1 // PARAVIS : ParaView wrapper SALOME module
3 // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License.
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
22 // File : PVGUI_Module.h
23 // Author : Sergey ANIKIN
26 #ifndef PVGUI_Module_H
27 #define PVGUI_Module_H
29 #include <LightApp_Module.h>
33 class LightApp_Selection;
34 class LightApp_SelectionMgr;
35 class PVGUI_ProcessModuleHelper;
42 class PVGUI_Module : public LightApp_Module
78 SelectPointsThroughId,
100 AnimationInspectorId,
102 ComparativeViewInspectorId,
103 SelectionInspectorId,
125 CreateCustomFilterId,
126 ManageCustomFiltersId,
130 ManagePluginsExtensionsId,
133 RecordTestScreenshotId,
146 lgLoadFile = 931, //!< load text file
147 lgSaveFile, //!< save text file
148 lgDisplayLine, //!< display selected line
149 lgEraseLine, //!< erase selected line
150 lgEditLine, //!< edit selected line
151 lgAddLine, //!< insert new line
152 lgDelLine, //!< delete selected line
153 lgClear //!< clear all contents
161 virtual void initialize( CAM_Application* );
162 virtual void windows( QMap<int, int>& ) const;
164 //virtual LightApp_Selection* createSelection() const;
166 pqViewManager* getMultiViewManager() const;
168 virtual bool eventFilter( QObject*, QEvent* );
171 //virtual CAM_DataModel* createDataModel();
174 //! Initialize ParaView if not yet done (once per session)
175 static bool pvInit();
176 //! Shutdown ParaView, should be called on application exit
177 static void pvShutdown();
179 //! Create actions for ParaView GUI operations
180 //! duplicating menus and toolbars in pqMainWindow ParaView class
181 void pvCreateActions();
183 //! Create menus for ParaView GUI operations
184 //! duplicating menus in pqMainWindow ParaView class
185 void pvCreateMenus();
187 //! Create toolbars for ParaView GUI operations
188 //! duplicating toolbars in pqMainWindow ParaView class
189 void pvCreateToolBars();
191 //! Create dock widgets for ParaView widgets
192 void setupDockWidgets();
194 //! Create dock widgets context menus
195 void setupDockWidgetsContextMenu();
197 //! Save states of dockable ParaView widgets
198 void saveDockWidgetsState();
200 //! Restore states of dockable ParaView widgets
201 void restoreDockWidgetsState();
203 //! Shows or hides ParaView view window
204 void showView( bool );
206 //! Returns QMenu object for a given menu id
207 QMenu* getMenu( const int );
210 void onUndoLabel( const QString& );
211 void onRedoLabel( const QString& );
213 void onCameraUndoLabel( const QString& );
214 void onCameraRedoLabel( const QString& );
218 void onSelectionModeChanged( int mode );
220 void onShowCenterAxisChanged( bool );
222 void setTimeRanges( double, double );
224 void onPlaying( bool );
226 void onAddCameraLink();
230 void showHelpForProxy( const QString& proxy );
231 void makeAssistant();
232 void assistantError( const QString& err );
236 void endWaitCursor();
239 virtual bool activateModule( SUIT_Study* );
240 virtual bool deactivateModule( SUIT_Study* );
243 class pqImplementation;
244 pqImplementation* Implementation;
246 int mySelectionControlsTb;
250 QList<QDockWidget*> myDockWidgets;
253 #endif // PVGUI_Module_H