X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=src%2FcreaImageIOWxDescriptorPanel.cpp;fp=src%2FcreaImageIOWxDescriptorPanel.cpp;h=9f563b66493cee26f216d0f00ff303d4dbb75781;hb=26b4c3303c14bfef570ad5671627ba5e01519f83;hp=60868d45ab7e65817e5c4eb73161c799c99b4fd3;hpb=b52bf19755b9e9f7d4a40abb2c8e881b56d49577;p=creaImageIO.git diff --git a/src/creaImageIOWxDescriptorPanel.cpp b/src/creaImageIOWxDescriptorPanel.cpp index 60868d4..9f563b6 100644 --- a/src/creaImageIOWxDescriptorPanel.cpp +++ b/src/creaImageIOWxDescriptorPanel.cpp @@ -109,7 +109,14 @@ namespace creaImageIO // 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 ); @@ -588,7 +595,12 @@ namespace creaImageIO ////////////////////////////////////////////////// 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(); @@ -635,7 +647,12 @@ namespace creaImageIO 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"),