1 // Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE
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.
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.
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
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
20 // File : SMESHGUI_MeshOrderOp.h
21 // Author : Pavel TELKOV, Open CASCADE S.A.S.
23 #ifndef SMESHGUI_MeshOrderOp_H
24 #define SMESHGUI_MeshOrderOp_H
28 #include "SMESH_SMESHGUI.hxx"
30 #include "SMESHGUI_Operation.h"
31 #include "SMESHGUI_MeshOrderDlg.h"
34 #include <SALOMEconfig.h>
35 #include CORBA_SERVER_HEADER(SMESH_Gen)
36 #include CORBA_SERVER_HEADER(SMESH_Mesh)
39 * \brief Operator to check and modify mesh computation submesh priority (order)
41 class SMESHGUI_EXPORT SMESHGUI_MeshOrderMgr
44 SMESHGUI_MeshOrderMgr( SMESHGUI_MeshOrderBox* );
45 virtual ~SMESHGUI_MeshOrderMgr();
46 //! Set root mesh object
47 void SetMesh( SMESH::SMESH_Mesh_var& theMesh );
48 //! Check for concurents between submesh objects
50 //! Check for concurents between submesh objects
51 bool GetMeshOrder( ListListId& theIds );
52 //! Store submesh priority order
54 //! Store given submesh priority order
55 bool SetMeshOrder( const ListListId& theIds );
57 //! Returns status is order changed by user
58 bool IsOrderChanged() const;
61 SMESH::SMESH_Mesh_var myMesh;
62 SMESHGUI_MeshOrderBox* myBox;
66 * \brief Operator to check and modify mesh computation submesh priority (order)
68 class SMESHGUI_EXPORT SMESHGUI_MeshOrderOp: public SMESHGUI_Operation
73 SMESHGUI_MeshOrderOp();
74 virtual ~SMESHGUI_MeshOrderOp();
77 virtual LightApp_Dialog* dlg() const;
79 virtual void startOperation();
81 //! sets the dialog widgets to state just after operation start
82 virtual void initDialog();
85 virtual bool onApply();
86 virtual void onCancel();
89 SMESHGUI_MeshOrderDlg* myDlg;
90 SMESHGUI_MeshOrderMgr* myMgr;
93 #endif // SMESHGUI_MeshOrderOp_H