| 17 | |
| 18 | #pragma region MyFrame |
| 19 | MyFrame::MyFrame(const wxString &title, const wxPoint &pos, const wxSize &size) |
| 20 | : wxFrame(NULL, wxID_ANY, title, pos, size) |
| 21 | { |
| 22 | ETF_kernel = 5; |
| 23 | ETF_iteration = 0; |
| 24 | FDoG_iteration = 0; |
| 25 | |
| 26 | #pragma region MenuBar |
| 27 | wxMenu *menuFile = new wxMenu; |
| 28 | menuFile->Append(ID_ONOPENSRC, "&Open SrcImg\tCtrl-O", "Open source image"); |
| 29 | |
| 30 | menuFile->Append(ID_ONSAVE, "&Save\tCtrl-S", "Save Result"); |
| 31 | menuFile->AppendSeparator(); |
| 32 | |
| 33 | menuFile->Append(wxID_EXIT); |
| 34 | |
| 35 | wxMenu *menuHelp = new wxMenu; |
| 36 | menuHelp->Append(wxID_ABOUT, "&About", "About the System"); |
| 37 | menuHelp |
| 38 | ->Append( |
| 39 | new wxMenuItem(menuHelp, wxID_TOGGLE_LOG, wxString(wxT("&Log\tCtrl-L")), "Show/Hide the Log", wxITEM_CHECK)) |
| 40 | ->Check(true); |
| 41 | |
| 42 | wxMenuBar *menuBar = new wxMenuBar; |
| 43 | menuBar->Append(menuFile, "&File"); |
| 44 | menuBar->Append(menuHelp, "&Help"); |
| 45 | SetMenuBar(menuBar); |
| 46 | CreateStatusBar(3); |
| 47 | SetStatusText("SrcImg: None", 0); |
| 48 | SetStatusText("ETF: None", 1); |
| 49 | SetStatusText("FDoG: None", 2); |
| 50 | |
| 51 | #pragma endregion |
| 52 | |
| 53 | #pragma region ToolBar : Buttons(Start, Fill Ink, Clean), Combobox(processingBox) |
| 54 | wxToolBar *toolbar1 = CreateToolBar(); |
| 55 | start = new wxButton(toolbar1, BUTTON_Start, _T("Start"), wxDefaultPosition, wxSize(100, 30), 0); |
| 56 | clean = new wxButton(toolbar1, BUTTON_Clean, _T("Clean"), wxDefaultPosition, wxSize(100, 30), 0); |
| 57 | |
| 58 | processingBox = |
| 59 | new wxComboBox(toolbar1, COMBOBOX_Processing, MODE_ORIGINIAL_IMAGE, wxDefaultPosition, wxSize(200, 30), 0); |
| 60 | processingBox->Append(MODE_ORIGINIAL_IMAGE); |
| 61 | processingBox->Append(MODE_ETF); |
| 62 | processingBox->Append(MODE_ETF_DEBUG); |
| 63 | processingBox->Append(MODE_CLD); |
| 64 | processingBox->Append(MODE_ANTI_ALIASING); |
| 65 | |
| 66 | |
| 67 | toolbar1->AddControl(start); |
| 68 | toolbar1->AddControl(clean); |
| 69 | toolbar1->AddControl(processingBox); |
| 70 | |
| 71 | |
| 72 | toolbar1->Realize(); |
| 73 | SetToolBar(toolbar1); |
| 74 | #pragma endregion |
| 75 | |
| 76 | //Sizer of whole window |
nothing calls this directly
no outgoing calls
no test coverage detected