1 // Copyright (C) 2007-2012 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 : AdvancedGUI.cxx
21 // Author : Vadim SANDLER, Open CASCADE S.A.S. (vadim.sandler@opencascade.com)
23 #include "AdvancedGUI.h"
25 #include "GeometryGUI.h"
26 #include "GeometryGUI_Operations.h"
28 #include <SUIT_Desktop.h>
29 #include <SalomeApp_Application.h>
31 #include "AdvancedGUI_PipeTShapeDlg.h"
32 #include "AdvancedGUI_DividedDiskDlg.h"
33 #include "AdvancedGUI_DividedCylinderDlg.h"
34 //@@ insert new functions before this line @@ do not remove this line @@ do not remove this line @@//
38 //=======================================================================
39 // function : AdvancedGUI()
40 // purpose : Constructor
41 //=======================================================================
42 AdvancedGUI::AdvancedGUI( GeometryGUI* parent ) : GEOMGUI( parent )
46 //=======================================================================
47 // function : ~AdvancedGUI
48 // purpose : Destructor
49 //=======================================================================
50 AdvancedGUI::~AdvancedGUI()
54 //=======================================================================
55 // function : OnGUIEvent()
57 //=======================================================================
58 bool AdvancedGUI::OnGUIEvent( int theCommandID, SUIT_Desktop* parent )
60 SalomeApp_Application* app = getGeometryGUI()->getApp();
61 if ( !app ) return false;
63 getGeometryGUI()->EmitSignalDeactivateDialog();
67 switch ( theCommandID ) {
68 case GEOMOp::OpPipeTShape:
69 aDlg = new AdvancedGUI_PipeTShapeDlg( getGeometryGUI(), parent );
71 // case GEOMOp::OpPipeTShapeGroups:
72 // aDlg = new AdvancedGUI_PipeTShapeGroupsDlg( getGeometryGUI(), parent );
74 case GEOMOp::OpDividedDisk:
75 aDlg = new AdvancedGUI_DividedDiskDlg( getGeometryGUI(), parent );
77 case GEOMOp::OpDividedCylinder:
78 aDlg = new AdvancedGUI_DividedCylinderDlg( getGeometryGUI(), parent );
80 //@@ insert new functions before this line @@ do not remove this line @@ do not remove this line @@//
82 app->putInfo( tr( "GEOM_PRP_COMMAND" ).arg( theCommandID ) );
92 //=====================================================================================
94 //=====================================================================================
98 __declspec( dllexport )
100 GEOMGUI* GetLibGUI( GeometryGUI* parent )
102 return new AdvancedGUI( parent );