1 // Copyright (C) 2006-2008 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.
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
19 #ifndef _ITEMEDITION_HXX_
20 #define _ITEMEDITION_HXX_
24 #include "guiObservers.hxx"
26 #include "FormEditItem.hxx"
33 class TablePortsEdition;
35 class ItemEditionBase: public GuiObserver
38 ItemEditionBase(Subject* subject);
39 virtual ~ItemEditionBase();
40 virtual void select(bool isSelected);
41 virtual void synchronize();
42 virtual void update(GuiEvent event, int type, Subject* son);
43 virtual Subject* getSubject();
49 std::string _category;
52 class ItemEdition: public FormEditItem, public ItemEditionBase
57 virtual void onApply();
58 virtual void onCancel();
59 virtual void onModifyName(const QString &text);
62 ItemEdition(Subject* subject,
64 const char* name = 0);
65 virtual ~ItemEdition();
66 virtual void synchronize();
67 virtual void select(bool isSelected);
68 virtual void setName(std::string name);
69 virtual void update(GuiEvent event, int type, Subject* son);
72 virtual void setEdited(bool isEdited);
77 class ItemEditionRoot: public ItemEdition
80 ItemEditionRoot(Subject* subject,
82 const char* name = 0);
83 virtual ~ItemEditionRoot();