void WxAnySimpleDlg::OnReadFile(wxCommandEvent& event)
{
int resultShowModal;
+//EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+#if wxMAJOR_VERSION <= 2
wxFileDialog* fileDlg = new wxFileDialog( 0, _T("Select file"), _T(""), _T(""), crea::std2wx("*"), wxOPEN |wxFD_MULTIPLE, wxDefaultPosition);
+#else
+ wxFileDialog* fileDlg = new wxFileDialog( 0, _T("Select file"), _T(""), _T(""), crea::std2wx("*"), wxFD_OPEN |wxFD_MULTIPLE, wxDefaultPosition);
+#endif
resultShowModal = fileDlg->ShowModal();
if ( resultShowModal==wxID_OK )
// RESULT
+//EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+#if wxMAJOR_VERSION <= 2
ResultCtrl=new wxTextCtrl(this, ID_EL_CTRL,_T(""), wxPoint(5,150), wxSize(250,310), wxTE_READONLY| wxMac | wxTE_MULTILINE | wxTE_RICH );
+#else
+ ResultCtrl=new wxTextCtrl(this, ID_EL_CTRL,_T(""), wxPoint(5,150), wxSize(250,310), wxTE_READONLY| wxTE_MULTILINE | wxTE_RICH );
+#endif
+
+
wxButton *RemoveCtrl = new wxButton(this, ID_REMOVE_ADD,_T("Remove an entry"), wxPoint(280,200) );
Connect( RemoveCtrl->GetId(), wxEVT_COMMAND_BUTTON_CLICKED , (wxObjectEventFunction) &WxDescriptorPanel::OnRemove );
//////////////////////////////////////////////////
void WxDescriptorPanel::OnLoad(wxCommandEvent &Event)
{
+//EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+#if wxMAJOR_VERSION <= 2
long style = wxOPEN | wxFILE_MUST_EXIST;
+#else
+ long style = wxFD_OPEN | wxFD_FILE_MUST_EXIST;
+#endif
LevelCtrl->SetValue(_T("patient"));
ResultCtrl->Clear();
DscpTree.clear();
const std::string WxDescriptorPanel::saveDescriptor()
{
std::string file = "";
+//EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+#if wxMAJOR_VERSION <= 2
long style = wxSAVE;
+#else
+ long style = wxFD_SAVE;
+#endif
std::string wc("*.dscp");
wxFileDialog* FD = new wxFileDialog( 0,
_T("Select file"),
wxToolBar *mToolBar = new wxToolBar(this,-1,wxDefaultPosition,wxDefaultSize);
mToolBar->AddTool( DUMP_SAVE_ID,_T("Save"), mIcon->GetBitmap(0), _T("Save Dicom Tags in text file"));
mToolBar->Realize();
+
+//EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+#if wxMAJOR_VERSION <= 2
DumpText = new wxTextCtrl( this, wxID_ANY,_T(""), wxPoint(5,30), wxSize(520,510), wxTE_READONLY| wxMac | wxTE_MULTILINE | wxTE_RICH );
+#else
+ DumpText = new wxTextCtrl( this, wxID_ANY,_T(""), wxPoint(5,30), wxSize(520,510), wxTE_READONLY | wxTE_MULTILINE | wxTE_RICH );
+#endif
+
Layout();
Print();
}
///////////////////////////////////////////////////
void WxDumpPanel::SaveInfos(wxCommandEvent& event)
{
+//EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+#if wxMAJOR_VERSION <= 2
wxFileDialog* FD = new wxFileDialog( 0,_T("Select file"), _T(""), _T(""),
crea::std2wx("*.txt"), wxOPEN, wxDefaultPosition);
+#else
+ wxFileDialog* FD = new wxFileDialog( 0,_T("Select file"), _T(""), _T(""),
+ crea::std2wx("*.txt"), wxFD_OPEN, wxDefaultPosition);
+#endif
if (FD->ShowModal()==wxID_OK)
{
wxBusyCursor busy;
Connect( _addCheckBox->GetId(), wxEVT_COMMAND_CHECKBOX_CLICKED, (wxObjectEventFunction) &WxGimmickTools::onAddToDatabase );
Connect( _mhdCheckBox->GetId(), wxEVT_COMMAND_CHECKBOX_CLICKED, (wxObjectEventFunction) &WxGimmickTools::onMHD );
+//EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+#if wxMAJOR_VERSION <= 2
wxFlexGridSizer *textSizer = new wxFlexGridSizer(1,2);
+#else
+ wxFlexGridSizer *textSizer = new wxFlexGridSizer(2);
+#endif
+
textSizer->Add( new wxStaticText(this, -1, _T("Transform a Bruker 'Serie'/'Study'/'set of Studies' directory into Dicom / MHD format.")), 1, wxGROW );
textSizer->Add( new wxStaticText(this, -1, _T("If checkbox is selected images will be loaded into the DB.")), 1, wxGROW );
+//EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+#if wxMAJOR_VERSION <= 2
wxFlexGridSizer *sizer = new wxFlexGridSizer(2,5);
+#else
+ wxFlexGridSizer *sizer = new wxFlexGridSizer(5);
+#endif
sizer->Add( new wxStaticText(this, -1, _T(" ")), 1, wxGROW );
sizer->Add( new wxStaticText(this, -1, _T(" ")), 1, wxGROW );
sizer->Add( _inputPath, 1, wxGROW );
sizer->Add( _addCheckBox, 1, wxGROW );
sizer->Add( _mhdCheckBox, 1, wxGROW );
+//EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+#if wxMAJOR_VERSION <= 2
wxFlexGridSizer *topSizer = new wxFlexGridSizer(1, 2);
+#else
+ wxFlexGridSizer *topSizer = new wxFlexGridSizer(2);
+#endif
topSizer->Add( textSizer, 1, wxGROW );
topSizer->Add( sizer, 1, wxGROW );
this->SetSizer( topSizer );
void WxGimmickView::OnAddFiles(wxCommandEvent& event)
{
mViewer->StopPlayer();
+
+//EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+#if wxMAJOR_VERSION <= 2
long style = wxOPEN | wxFILE_MUST_EXIST | wxFD_MULTIPLE;
+#else
+ long style = wxFD_OPEN | wxFD_FILE_MUST_EXIST | wxFD_MULTIPLE;
+#endif
+
+
std::string wc("*");
wxFileDialog* FD = new wxFileDialog( 0,
_T("Select file"),
void WxSimpleDlg::OnReadFile(wxCommandEvent& event)
{
int resultShowModal;
+//EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+#if wxMAJOR_VERSION <= 2
wxFileDialog* fileDlg = new wxFileDialog( 0, _T("Select file"), _T(""), _T(""), crea::std2wx("*"), wxOPEN |wxFD_MULTIPLE, wxDefaultPosition);
+#else
+ wxFileDialog* fileDlg = new wxFileDialog( 0, _T("Select file"), _T(""), _T(""), crea::std2wx("*"), wxFD_OPEN |wxFD_MULTIPLE, wxDefaultPosition);
+#endif
resultShowModal = fileDlg->ShowModal();
if ( resultShowModal==wxID_OK )