Code_TYMPAN  4.4.0
Industrial site acoustic simulation
TYProjetFrame.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) <2012-2024> <EDF-DTG> <FRANCE>
3  * This file is part of Code_TYMPAN (R).
4  * Code_TYMPAN (R) is free software: you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License as published by
6  * the Free Software Foundation, either version 3 of the License, or
7  * (at your option) any later version.
8  * Code_TYMPAN (R) 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.
11  * See the GNU General Public License for more details.
12  * You should have received a copy of the GNU General Public License along
13  * with Code_TYMPAN (R). If not, see <https://www.gnu.org/licenses/>.
14  */
15 
23 #ifndef __TY_PROJET_FRAME__
24 #define __TY_PROJET_FRAME__
25 
26 #include <qwidget.h>
27 // Added by qt3to4:
28 #include <QKeyEvent>
29 #include <QTreeWidget>
30 
31 #include "TYAppDefines.h"
32 
33 class QMenuBar;
34 class TYSpectresManagerFrame;
35 
40 class TYProjetFrame : public QWidget
41 {
42  Q_OBJECT
43 
44 public:
48  TYProjetFrame(QWidget* parent = 0, const char* name = 0, Qt::WindowFlags f = QFlag(0));
52  virtual ~TYProjetFrame();
53 
58  {
59  return _pProjet;
60  }
61 
65  void clear()
66  {
67  _pListView->clear();
68  }
69 
70  TYSpectresManagerFrame* getTYSpectresManagerFrame()
71  {
73  };
74 
78  void setCalculDone(bool state);
79 
80 public slots:
84  void setProjet(LPTYProjet pProjet);
85 
89  void updateList();
90 
95  TYElementListItem* addToList(LPTYProjet pElement, TYElementListItem* parent = NULL);
100  TYElementListItem* addToList(LPTYCalcul pElement, TYElementListItem* parent = NULL);
101 
105  virtual void contextMenuEvent(QContextMenuEvent* e);
106 
107  void keyPressEvent(QKeyEvent* e);
108 
112  void doubleClic(QTreeWidgetItem*, int);
113 
120  void apply(QTreeWidgetItem* item, int col);
121 
122 signals:
131 
132 protected:
137  TYElementListItem* addEltToList(LPTYElement pElement, TYElementListItem* parent = NULL);
138 
145  bool remFromList(TYElementListItem* item);
146 
150  void exportMaillageCSV(const LPTYMaillage pMaillage);
151 
155  void setCalculItemState(TYElementListItem* pCalcItem, bool state);
156 
160  void selectOrUnselectAll(TYElementListItem* item, const bool& bSelect);
161 
165  void updateGraphics();
166 
171  void highlight_element(TYElementGraphic* pGraphicObject, TYElement* pElement);
172 
173 protected:
174  QMenuBar* _pMenuBar;
175  QTreeWidget* _pListView;
176 
179 
182 
185 
186  TYSpectresManagerFrame* _pSpectresManagerFrame;
187 };
188 
189 #endif //__TY_PROJET_FRAME__
const char * name
classe graphique pour un element de base
Frame pour les messages de retour.
Frame pour la gestion de projet.
Definition: TYProjetFrame.h:41
void apply(QTreeWidgetItem *item, int col)
bool remFromList(TYElementListItem *item)
void setCalculDone(bool state)
LPTYProjet getProjet()
Definition: TYProjetFrame.h:57
void changeSite(LPTYSiteNode pSite)
TYElementListItem * addEltToList(LPTYElement pElement, TYElementListItem *parent=NULL)
void setCalculItemState(TYElementListItem *pCalcItem, bool state)
LPTYProjet _pProjet
Le projet.
virtual void contextMenuEvent(QContextMenuEvent *e)
void keyPressEvent(QKeyEvent *e)
void selectOrUnselectAll(TYElementListItem *item, const bool &bSelect)
TYElementListItem * addToList(LPTYProjet pElement, TYElementListItem *parent=NULL)
QMenuBar * _pMenuBar
TYProjetFrame(QWidget *parent=0, const char *name=0, Qt::WindowFlags f=QFlag(0))
TYElementListItem * _pCurrentCalculItem
L'item du treeview du projet.
QTreeWidget * _pListView
void setProjet(LPTYProjet pProjet)
void updateGraphics()
void updateGraphics()
void exportMaillageCSV(const LPTYMaillage pMaillage)
void changeCurrentCalcul(LPTYCalcul pCalcul)
virtual ~TYProjetFrame()
void highlight_element(TYElementGraphic *pGraphicObject, TYElement *pElement)
highlight object
LPTYCalcul _pCurrentCalcul
Le calcul courant.
void doubleClic(QTreeWidgetItem *, int)
TYSpectresManagerFrame * getTYSpectresManagerFrame()
Definition: TYProjetFrame.h:70
TYSpectresManagerFrame * _pSpectresManagerFrame