1 // Copyright (C) 2009-2016 CEA/DEN, EDF R&D
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
20 #ifndef _BL_GENERICGUI_HXX_
21 #define _BL_GENERICGUI_HXX_
23 #include "BL_GenericGuiDefines.hxx"
25 #include "BL_Traces.hxx"
27 #include "BL_SALOMEServices.hxx"
29 #include "BL_MainWindows_Wrap.hxx"
31 #include "BL_QModelManager.hxx"
32 #include "BL_JobsManager_QT.hxx"
33 #include "BL_JobsTable.hxx"
34 #include "BL_JobTab.hxx"
35 #include "BL_Buttons.hxx"
36 #include "BL_Summary.hxx"
37 #include "JM_ResourceCatalog.hxx"
48 class BL_GenericGui_EXPORT GenericGui: public QObject
53 GenericGui(BL::MainWindows_Wrap * wrapper);
54 virtual ~GenericGui();
56 void createDockWidgets();
57 void createCentralWidget();
59 void showDockWidgets(bool isVisible);
63 void delete_job_internal();
65 void deleteDockWidget();
66 void delete_job_external(const QString & name);
68 void reset_job_selection();
73 void edit_clone_job();
79 void get_results_job();
80 void job_selected(const QModelIndex & index);
81 void job_activated(const QModelIndex & index);
82 void job_state_changed(const QString & name);
83 void updateButtonsStates();
84 void updateButtonsStatesSingleSelection();
87 BL::JobTab * _job_tab;
88 BL::JobsTable * _jobs_table;
91 BL::MainWindows_Wrap * _wrapper;
93 BL::SALOMEServices * _salome_services;
95 QMainWindow * _dock_parent;
96 QMainWindow * _tab_parent;
97 QDockWidget * _dw_summary;
98 QDockWidget * _dw_resource_catalog;
100 BL::Buttons * _buttons;
101 BL::Summary * _summary;
103 QAction * _create_job_action;
104 QAction * _edit_clone_job_action;
105 QAction * _start_job_action;
106 QAction * _restart_job_action;
107 QAction * _delete_job_action;
108 QAction * _stop_job_action;
109 QAction * _get_results_job_action;
110 QAction * _refresh_job_action;
112 BL::JobsManager_QT * _jobs_manager;
113 BL::QModelManager * _model_manager;
114 QStandardItemModel * _model;
115 JM::ResourceCatalog * _resource_catalog;
117 QString _job_name_selected;