]> SALOME platform Git repositories - modules/homard.git/blob - src/HOMARDGUI/HOMARDGUI.h
Salome HOME
Porting HOMARD SALOME module to the CMake build system: initial version.
[modules/homard.git] / src / HOMARDGUI / HOMARDGUI.h
1 // Copyright (C) 2011-2013  CEA/DEN, EDF R&D
2 //
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.
7 //
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.
12 //
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
16 //
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 //
19
20 //  HOMARDGUI : HOMARD component GUI implemetation
21 //
22
23 #ifndef _HOMARDGUI_H_
24 #define _HOMARDGUI_H_
25
26 #include <SalomeApp_Module.h>
27 #include "SalomeApp_Study.h"
28
29 #include <SALOMEconfig.h>
30 #include <SALOME_LifeCycleCORBA.hxx>
31 #include CORBA_CLIENT_HEADER(HOMARD_Gen)
32 #include CORBA_CLIENT_HEADER(HOMARD_Cas)
33 #include CORBA_CLIENT_HEADER(HOMARD_Hypothesis)
34
35 #include <QtCore/QString>
36
37 class SalomeApp_Application;
38
39 class HOMARDGUI: public SalomeApp_Module
40 {
41   Q_OBJECT
42
43 public:
44    HOMARDGUI(const QString&);
45   ~HOMARDGUI();
46
47
48
49   virtual bool OnGUIEvent (int theCommandID);
50   void    initialize( CAM_Application* );
51   QString engineIOR() const;
52   void    windows( QMap<int, int>& ) const;
53
54   static HOMARD::HOMARD_Gen_var InitHOMARDGen(SalomeApp_Application* );
55
56
57 public slots:
58     bool    deactivateModule( SUIT_Study* );
59     bool    activateModule( SUIT_Study* );
60     static void setOrb();
61
62 private slots:
63     void OnGUIEvent();
64     void EditAsciiFile();
65     void LanceCalcul();
66     void IterInfo();
67     void NextIter();
68     void YACSCreate();
69     void YACSWrite();
70     void Edit();
71     void Delete();
72
73 public:
74    virtual void  contextMenuPopup( const QString&, QMenu*, QString& );
75
76
77 private:
78    void createHOMARDAction( const int id, const QString& po_id, const QString& icon_id = QString(""),
79                             const int key = 0, const bool toggle = false );
80    void createActions();
81    void createMenus();
82    void createPopupMenus();
83    _PTR(SObject)  chercheMonObjet();
84
85    virtual void createPreferences();
86    HOMARD::HOMARD_Gen_var myComponentHomard;
87    SALOMEDS::Study_var       myStudy;
88
89    int anId;
90    QString _ObjectName;
91    QString _LanguageShort ;
92 };
93
94 #endif