1 // Copyright (C) 2013-2014 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, or (at your option) any later version.
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
23 #include "GeometryGUI.h"
24 #include "GeometryGUI_Operations.h"
27 #include <SUIT_Desktop.h>
28 #include <SUIT_Desktop.h>
29 #include <SUIT_MessageBox.h>
30 #include <SalomeApp_Application.h>
32 #include "ImportExportGUI_ExportXAODlg.h"
33 #include "ImportExportGUI_ImportXAODlg.h"
34 #include "ImportExportGUI.h"
35 //@@ insert new functions before this line @@ do not remove this line @@ do not remove this line @@//
38 //=======================================================================
39 // function : ImportExportGUI()
40 // purpose : Constructor
41 //=======================================================================
42 ImportExportGUI::ImportExportGUI(GeometryGUI* parent) :
47 //=======================================================================
48 // function : ~ImportExportGUI
49 // purpose : Destructor
50 //=======================================================================
51 ImportExportGUI::~ImportExportGUI()
55 //=======================================================================
56 // function : OnGUIEvent()
58 //=======================================================================
59 bool ImportExportGUI::OnGUIEvent(int commandId, SUIT_Desktop* parent)
61 SalomeApp_Application* app = getGeometryGUI()->getApp();
62 if (!app) return false;
64 getGeometryGUI()->EmitSignalDeactivateDialog();
66 QDialog* dialog = NULL;
69 case GEOMOp::OpExportXAO:
70 dialog = new ImportExportGUI_ExportXAODlg(getGeometryGUI(), parent);
72 case GEOMOp::OpImportXAO:
73 dialog = new ImportExportGUI_ImportXAODlg(getGeometryGUI(), parent);
75 //@@ insert new functions before this line @@ do not remove this line @@ do not remove this line @@//
77 app->putInfo(tr("GEOM_PRP_COMMAND").arg(commandId));
87 //=====================================================================================
89 //=====================================================================================
93 __declspec( dllexport )
95 GEOMGUI* GetLibGUI(GeometryGUI* parent)
97 return new ImportExportGUI(parent);