Version: 8.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
PVViewer_GUIElements.h
Go to the documentation of this file.
1 // Copyright (C) 2014-2016 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, or (at your option) any later version.
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 // Author: Adrien Bruneton (CEA)
20 
21 #ifndef PVVIEWERGUIELEMENTS_H_
22 #define PVVIEWERGUIELEMENTS_H_
23 
24 #include "PVViewer.h"
25 
26 #include <QObject>
27 #include <QList>
28 
29 class pqPropertiesPanel;
30 class pqPipelineBrowserWidget;
31 class pqPipelineModel;
32 class QMainWindow;
33 class QMenu;
34 class QToolBar;
35 class QAction;
36 class pqAnimationTimeToolbar;
37 class pqVCRToolbar;
38 
44 {
45  Q_OBJECT
46 
47 public:
48  static PVViewer_GUIElements * GetInstance(QMainWindow * desk);
49 
50  pqPropertiesPanel * getPropertiesPanel();
51  pqPipelineBrowserWidget * getPipelineBrowserWidget();
52 
53  QMenu* getFiltersMenu();
54  QMenu* getSourcesMenu();
55  QMenu* getMacrosMenu();
56 
57  pqVCRToolbar* getVCRToolbar();
58  pqAnimationTimeToolbar* getTimeToolbar();
59 
60  void setToolBarVisible(bool show);
61  void setToolBarEnabled(bool enabled);
62  QList<QToolBar*> getToolbars();
63 
64  void setVCRTimeToolBarVisible(bool show);
65 
66 private:
68  virtual ~PVViewer_GUIElements() {}
69 
71 
72  void buildPVWidgets();
73 
74  void publishExistingSources();
75 
76  // Widgets
77  pqPropertiesPanel* propertiesPanel;
78  pqPipelineBrowserWidget* pipelineBrowserWidget;
79  pqPipelineModel* pipelineModel;
80 
81  // Dummy QMenus receiving ParaView's reaction for automatic add when new sources are added
85 
86  // Toolbars also need to be instanciated early:
88  pqVCRToolbar* vcrToolbar;
89  pqAnimationTimeToolbar* timeToolbar;
97 
100 
101 public:
112 };
113 
114 #endif /* PVVIEWERGUIELEMENTS_H_ */