1 #ifndef WXMARACASSURFACERENDERINGPANEL_H_
2 #define WXMARACASSURFACERENDERINGPANEL_H_
6 class wxMaracasSurfaceRenderingPanel : public wxPanel{
8 wxMaracasSurfaceRenderingPanel(wxWindow* parent, int propid, bool _isComplexBox, int _panID)
9 : wxPanel(parent, -1, wxDefaultPosition, wxDefaultSize){
11 isComplexBox = _isComplexBox;
15 //virtual ~wxMaracasSurfaceRenderingPanel();
16 virtual void createPanel(){
18 /*wxBoxSizer* sizerButtons = new wxBoxSizer(wxVERTICAL);
20 wxButton* b = new wxButton(this, -1, wxString(_T("-")), wxDefaultPosition, wxDefaultSize, wxBU_EXACTFIT,
21 wxDefaultValidator, wxString(_T("-")));
22 Connect(b->GetId(), wxEVT_COMMAND_BUTTON_CLICKED, (wxObjectEventFunction)&wxMaracasSurfaceRenderingPanel::onActionButtonPressedHide);
23 wxButton* b1 = new wxButton(this, -1, wxString(_T("-")), wxDefaultPosition, wxDefaultSize, wxBU_EXACTFIT,
24 wxDefaultValidator, wxString(_T("x")));
25 Connect(b1->GetId(), wxEVT_COMMAND_BUTTON_CLICKED, (wxObjectEventFunction)&wxMaracasSurfaceRenderingPanel::onActionButtonPressedEliminate);
27 sizerButtons->Add(b, wxFIXED_MINSIZE);
28 sizerButtons->Add(b1, wxFIXED_MINSIZE);*/
30 sizercontrols = new wxBoxSizer(wxVERTICAL);
32 wxBoxSizer* sizerpanel = new wxBoxSizer(wxHORIZONTAL);
34 //sizerpanel->Add(sizerButtons,wxGROW);
35 sizerpanel->Add(sizercontrols,wxGROW);
37 this->SetSizer(sizerpanel, true);
38 this->SetAutoLayout( true );
42 ** Adds a new control to the panel (sizer, radiob, etc)
44 virtual void addControl(wxWindow* win){
45 if(sizercontrols!=NULL){
46 sizercontrols->Add(win, wxGROW);
51 ** Adds a new control to the panel (sizer, radiob, etc)
53 virtual void addControl(wxSizer* sizer){
54 if(sizercontrols!=NULL){
55 sizercontrols->Add(sizer, wxGROW);
60 ** Hides or show the controls in the panel
62 virtual void onActionButtonPressedHide( wxCommandEvent& event ){
63 // warning: wxListBase::operator wxList&() const is deprecated // JPR
64 wxList list = sizercontrols->GetChildren();
66 for(i=0; i<(int)list.size();i++){
67 sizercontrols->Show(i,show);
70 sizercontrols->Layout();
75 ** The user must implement this function to remove the panel from the
77 //virtual void onActionButtonPressedEliminate( wxCommandEvent& event )=0;
80 ** The user must implement this function to add the necessary controls to the panel
82 virtual void createControls( )=0;
85 ** returns the id of the panel
92 ** Returns the papnel id
99 ** Tells if the panel is used for a complex box
106 wxBoxSizer* sizercontrols;
111 //-- Atributes added for complex box --//
116 #endif /*WXMARACASSURFACERENDERINGPANEL_H_*/