1 #include "wxMaracasDialog_NViewers.h"
2 //#include <wx/frame.h>
6 BEGIN_EVENT_TABLE( wxMaracasDialog_NViewers, wxFrame )
7 EVT_MENU( 12121, wxMaracasDialog_NViewers::OnRefreshView )
8 EVT_MENU( 12122, wxMaracasDialog_NViewers::OnDClickLeft )
14 wxMaracasDialog_NViewers::wxMaracasDialog_NViewers(wxWindow* parent, vtkImageData* img, std::vector<int>* type, wxString title)
15 : wxFrame(parent, -1, title)
17 panelcut = new wxPanel(this, -1);
18 viewer = new wxMaracas_N_ViewersWidget(panelcut, img, type);
19 sizer = new wxFlexGridSizer(2);
21 sizer->Add(viewer, wxALL|wxEXPAND, 1);
22 panelcut->SetSizer( sizer, true );
23 panelcut->SetAutoLayout( true );
24 //viewer->SetSize(wxSizer(wxALL|wxEXPAND));
30 wxMaracasDialog_NViewers::~wxMaracasDialog_NViewers(){
34 ** Adds a new panel to the frame
36 void wxMaracasDialog_NViewers::AddPanel(wxWindow* panel)
38 //wxFlexGridSizer* sizer = new wxFlexGridSizer(1);
40 panel->SetSize(400, 200);
42 sizer->Add(panel, wxALL|wxEXPAND);
43 panelcut->SetSizer( sizer, true );
44 panelcut->SetAutoLayout( true );
50 void wxMaracasDialog_NViewers::OnRefreshView(wxCommandEvent & event)
53 point.push_back((int)viewer->GetX());
54 point.push_back((int)viewer->GetY());
55 point.push_back((int)viewer->GetZ());
57 viewer->OnRefreshView(event);
63 void wxMaracasDialog_NViewers::OnDClickLeft(wxCommandEvent & event)
65 viewer->OnDClickLeft(event);
71 wxMaracas_N_ViewersWidget* wxMaracasDialog_NViewers::getViewer()
79 wxPanel* wxMaracasDialog_NViewers::getinternalPanel()