Salome HOME
remove images in ascii
[modules/smesh.git] / src / SMESHGUI / SMESHGUI_MoveNodesDlg.h
1 //  SMESH SMESHGUI : GUI for SMESH component
2 //
3 //  Copyright (C) 2003  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 //  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 
5 // 
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. 
10 // 
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. 
15 // 
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 
19 // 
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21 //
22 //
23 //
24 //  File   : SMESHGUI_MoveNodesDlg.h
25 //  Author : Nicolas REJNERI
26 //  Module : SMESH
27 //  $Header$
28
29 #ifndef DIALOGBOX_MOVE_NODES_H
30 #define DIALOGBOX_MOVE_NODES_H
31
32 #include "SMESH_SMESHGUI.hxx"
33
34 #include "LightApp_SelectionMgr.h"
35
36 #include <qdialog.h>
37
38 class QLineEdit;
39 class QPushButton;
40 class SMESHGUI_SpinBox;
41 class SALOME_Actor;
42 class QFrame;
43
44 class SMESHGUI;
45 class SMESH_Actor;
46 class SUIT_Desktop;
47 class SVTK_Selector;
48 class SVTK_ViewWindow;
49
50 //=================================================================================
51 // class    : SMESHGUI_MoveNodesDlg
52 // purpose  :
53 //=================================================================================
54 class SMESHGUI_EXPORT SMESHGUI_MoveNodesDlg : public QDialog
55
56   Q_OBJECT
57
58 public:
59
60                                 SMESHGUI_MoveNodesDlg(SMESHGUI* theModule,
61                                                       const char* name = 0);
62  virtual                        ~SMESHGUI_MoveNodesDlg();
63     
64  void                           Init();
65
66 private slots:
67
68   void                          onOk();
69   bool                          onApply();
70   void                          onClose();
71   void                          onHelp();
72
73   void                          onDeactivate();
74
75   void                          onSelectionDone();
76   void                          redisplayPreview();
77   void                          onTextChange(const QString&);
78
79 private:
80
81   void                          closeEvent( QCloseEvent* e ) ;
82   void                          enterEvent ( QEvent * ) ;
83   void                          hideEvent ( QHideEvent * );
84   void                          erasePreview();
85   QFrame*                       createButtonFrame( QWidget* );
86   QFrame*                       createMainFrame  ( QWidget* );
87   bool                          isValid( const bool ) const;
88   void                          reset();
89   void                          updateButtons();
90
91 private:
92
93   QPushButton*                  myOkBtn;
94   QPushButton*                  myApplyBtn;
95   QPushButton*                  myCloseBtn;
96   QPushButton*                  myHelpBtn;
97   
98   QLineEdit*                    myId;
99   SMESHGUI_SpinBox*             myX;
100   SMESHGUI_SpinBox*             myY;
101   SMESHGUI_SpinBox*             myZ;
102
103   LightApp_SelectionMgr*        mySelectionMgr;
104   SVTK_Selector*                mySelector;
105   SMESHGUI*                     mySMESHGUI;
106   
107   SALOME_Actor*                 myPreviewActor;
108   SMESH_Actor*                  myMeshActor;
109   bool                          myBusy;
110
111   QString                       myHelpFileName;
112 };
113
114 #endif // DIALOGBOX_MOVE_NODES_H