Salome HOME
This commit was generated by cvs2git to create branch 'IMPORT'.
[modules/smesh.git] / src / SMESHGUI / SMESHGUI_AddVolumeDlg.h
1 //  File      : SMESHGUI_AddVolumeDlg.h
2 //  Created   : Wed Jun 26 21:00:41 2002
3 //  Author    : Nicolas REJNERI
4
5 //  Project   : SALOME
6 //  Module    : SMESH
7 //  Copyright : Open CASCADE 2002
8 //  $Header$
9
10
11 #ifndef DIALOGBOX_ADD_VOLUME_H
12 #define DIALOGBOX_ADD_VOLUME_H
13
14 #include "SALOME_Selection.h"
15
16 // QT Includes
17 #include <qvariant.h>
18 #include <qdialog.h>
19
20 // Open CASCADE Includes
21 #include <TColStd_MapOfInteger.hxx>
22
23 class QVBoxLayout; 
24 class QHBoxLayout; 
25 class QGridLayout; 
26 class QButtonGroup;
27 class QGroupBox;
28 class QLabel;
29 class QLineEdit;
30 class QPushButton;
31 class QRadioButton;
32 class QCheckBox;
33 class SMESHGUI;
34
35 // IDL Headers
36 #include <SALOMEconfig.h>
37 #include CORBA_SERVER_HEADER(SMESH_Mesh)
38
39 //=================================================================================
40 // class    : SMESHGUI_AddVolumeDlg
41 // purpose  :
42 //=================================================================================
43 class SMESHGUI_AddVolumeDlg : public QDialog
44
45     Q_OBJECT
46
47 public:
48     SMESHGUI_AddVolumeDlg( QWidget* parent = 0, const char* name = 0, SALOME_Selection* Sel = 0, 
49                              int nbNode = 4, bool modal = FALSE, WFlags fl = 0 );
50     ~SMESHGUI_AddVolumeDlg();
51
52 private:
53
54     void Init( SALOME_Selection* Sel ) ;
55     void closeEvent( QCloseEvent* e ) ;
56     void enterEvent ( QEvent * ) ;                          /* mouse enter the QWidget */
57
58     SMESHGUI*                     mySMESHGUI ;              /* Current SMESHGUI object */
59     SALOME_Selection*             mySelection ;             /* User shape selection */
60     bool                          myOkNodes ;               /* to check when arguments is defined */
61
62     int                           myNodes ;
63     int                           myConstructorId ;         /* Current constructor id = radio button id */
64     QLineEdit*                    myEditCurrentArgument;    /* Current  LineEdit */
65
66     SMESH::SMESH_Mesh_var         myMesh;
67     TColStd_MapOfInteger          myMapIndex;
68     
69     QButtonGroup* GroupConstructors;
70     QRadioButton* Constructor1;
71     QGroupBox* GroupButtons;
72     QPushButton* buttonOk;
73     QPushButton* buttonCancel;
74     QPushButton* buttonApply;
75     QGroupBox* GroupC1;
76     QLabel* TextLabelC1A1;
77     QPushButton* SelectButtonC1A1;
78     QLineEdit* LineEditC1A1;
79
80 private slots:
81
82     void ConstructorsClicked(int constructorId);
83     void ClickOnOk();
84     void ClickOnCancel();
85     void ClickOnApply();
86     void SetEditCurrentArgument() ;
87     void SelectionIntoArgument() ;
88     void DeactivateActiveDialog() ;
89     void ActivateThisDialog() ;
90
91 protected:
92     QGridLayout* SMESHGUI_AddVolumeDlgLayout;
93     QGridLayout* GroupConstructorsLayout;
94     QGridLayout* GroupButtonsLayout;
95     QGridLayout* GroupC1Layout;
96 };
97
98 #endif // DIALOGBOX_ADD_VOLUME_H