1 /*# ---------------------------------------------------------------------
3 # Copyright (c) CREATIS (Centre de Recherche en Acquisition et Traitement de l'Image
5 # Authors : Eduardo Davila, Frederic Cervenansky, Claire Mouton
6 # Previous Authors : Laurent Guigues, Jean-Pierre Roux
7 # CreaTools website : www.creatis.insa-lyon.fr/site/fr/creatools_accueil
9 # This software is governed by the CeCILL-B license under French law and
10 # abiding by the rules of distribution of free software. You can use,
11 # modify and/ or redistribute the software under the terms of the CeCILL-B
12 # license as circulated by CEA, CNRS and INRIA at the following URL
13 # http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
14 # or in the file LICENSE.txt.
16 # As a counterpart to the access to the source code and rights to copy,
17 # modify and redistribute granted by the license, users are provided only
18 # with a limited warranty and the software's author, the holder of the
19 # economic rights, and the successive licensors have only limited
22 # The fact that you are presently reading this means that you have had
23 # knowledge of the CeCILL-B license and that you accept its terms.
24 # ------------------------------------------------------------------------ */
26 #ifndef WXMARACASSURFACERENDERINGPANEL_H_
27 #define WXMARACASSURFACERENDERINGPANEL_H_
31 class wxMaracasSurfaceRenderingPanel : public wxPanel{
33 wxMaracasSurfaceRenderingPanel(wxWindow* parent, int propid, bool _isComplexBox, int _panID)
34 : wxPanel(parent, -1, wxDefaultPosition, wxDefaultSize){
36 isComplexBox = _isComplexBox;
40 //virtual ~wxMaracasSurfaceRenderingPanel();
41 virtual void createPanel(){
43 /*wxBoxSizer* sizerButtons = new wxBoxSizer(wxVERTICAL);
45 wxButton* b = new wxButton(this, -1, wxString(_T("-")), wxDefaultPosition, wxDefaultSize, wxBU_EXACTFIT,
46 wxDefaultValidator, wxString(_T("-")));
47 Connect(b->GetId(), wxEVT_COMMAND_BUTTON_CLICKED, (wxObjectEventFunction)&wxMaracasSurfaceRenderingPanel::onActionButtonPressedHide);
48 wxButton* b1 = new wxButton(this, -1, wxString(_T("-")), wxDefaultPosition, wxDefaultSize, wxBU_EXACTFIT,
49 wxDefaultValidator, wxString(_T("x")));
50 Connect(b1->GetId(), wxEVT_COMMAND_BUTTON_CLICKED, (wxObjectEventFunction)&wxMaracasSurfaceRenderingPanel::onActionButtonPressedEliminate);
52 sizerButtons->Add(b, wxFIXED_MINSIZE);
53 sizerButtons->Add(b1, wxFIXED_MINSIZE);*/
55 sizercontrols = new wxBoxSizer(wxVERTICAL);
57 wxBoxSizer* sizerpanel = new wxBoxSizer(wxHORIZONTAL);
59 //sizerpanel->Add(sizerButtons,wxGROW);
60 sizerpanel->Add(sizercontrols,wxGROW);
62 this->SetSizer(sizerpanel, true);
63 this->SetAutoLayout( true );
67 ** Adds a new control to the panel (sizer, radiob, etc)
69 virtual void addControl(wxWindow* win){
70 if(sizercontrols!=NULL){
71 sizercontrols->Add(win, wxGROW);
76 ** Adds a new control to the panel (sizer, radiob, etc)
78 virtual void addControl(wxSizer* sizer){
79 if(sizercontrols!=NULL){
80 sizercontrols->Add(sizer, wxGROW);
85 ** Hides or show the controls in the panel
87 virtual void onActionButtonPressedHide( wxCommandEvent& event ){
88 /// \TODO : fix deprecated : wxListBase::operator wxList&() const is deprecated // JPR
89 wxList list = sizercontrols->GetChildren();
91 for(i=0; i<(int)list.size();i++){
92 sizercontrols->Show(i,show);
95 sizercontrols->Layout();
100 ** The user must implement this function to remove the panel from the
102 //virtual void onActionButtonPressedEliminate( wxCommandEvent& event )=0;
105 ** The user must implement this function to add the necessary controls to the panel
107 virtual void createControls( )=0;
110 ** returns the id of the panel
117 ** Returns the papnel id
124 ** Tells if the panel is used for a complex box
131 wxBoxSizer* sizercontrols;
136 //-- Atributes added for complex box --//
141 #endif /*WXMARACASSURFACERENDERINGPANEL_H_*/