X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FcreaDevManagerLib%2FwxCDMApplicationDescriptionPanel.cpp;h=1ccf43580e8e80bf7e3aef7d33521f3b369fabcf;hb=5ff0bb2664c3cd508c1dd438666a71b8a96459c3;hp=7e8c6dc140259d112534d8a0812439cabfe0372d;hpb=e75a80c4a8a5d67aeb1e941f0c980a11c09cc125;p=crea.git diff --git a/lib/creaDevManagerLib/wxCDMApplicationDescriptionPanel.cpp b/lib/creaDevManagerLib/wxCDMApplicationDescriptionPanel.cpp index 7e8c6dc..1ccf435 100644 --- a/lib/creaDevManagerLib/wxCDMApplicationDescriptionPanel.cpp +++ b/lib/creaDevManagerLib/wxCDMApplicationDescriptionPanel.cpp @@ -208,7 +208,7 @@ void wxCDMApplicationDescriptionPanel::OnBtnReturn(wxHyperlinkEvent& event) if (parents[i]->GetPath() == parentURL) { wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_DISPLAY_CHANGED); - newEvent->SetInt(parents[i]->GetId()); + newEvent->SetClientData(parents[i]); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); } @@ -264,7 +264,7 @@ void wxCDMApplicationDescriptionPanel::OnBtnCreateClass(wxCommandEvent& event) wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_DISPLAY_CHANGED); newEvent->SetId(0); - newEvent->SetInt(this->application->GetId()); + newEvent->SetClientData(this->application); wxPostEvent(this->GetParent(), *newEvent); wxMessageBox(crea::std2wx("The class has been created successfully."),_T("New Class - Success"),wxOK | wxICON_INFORMATION); @@ -297,7 +297,7 @@ void wxCDMApplicationDescriptionPanel::OnBtnCreateFolder(wxCommandEvent& event) } ((wxCDMMainFrame*)this->GetParent())->RefreshProject(); wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_DISPLAY_CHANGED); - newEvent->SetInt(folderC->GetId()); + newEvent->SetClientData(folderC); wxPostEvent(this->GetParent(), *newEvent); wxMessageBox(crea::std2wx("The folder was successfully created"),_T("Create Folder - Success"),wxOK | wxICON_INFORMATION); } @@ -317,8 +317,7 @@ void wxCDMApplicationDescriptionPanel::OnBtnEditCMakeLists(wxCommandEvent& event if(this->application->GetCMakeLists() != NULL) { - int CMId = this->application->GetCMakeLists()->GetId(); - newEvent->SetInt(CMId); + newEvent->SetClientData(this->application->GetCMakeLists()); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); } @@ -339,8 +338,7 @@ void wxCDMApplicationDescriptionPanel::OnCMakeMouseEnter(wxMouseEvent& event) if(this->application->GetCMakeLists() != NULL) { - int CMId = this->application->GetCMakeLists()->GetId(); - newEvent->SetInt(CMId); + newEvent->SetClientData(this->application->GetCMakeLists()); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); } @@ -353,8 +351,7 @@ void wxCDMApplicationDescriptionPanel::OnCMakeMouseExit(wxMouseEvent& event) if(this->application->GetCMakeLists() != NULL) { - int CMId = this->application->GetCMakeLists()->GetId(); - newEvent->SetInt(CMId); + newEvent->SetClientData(this->application->GetCMakeLists()); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); } @@ -372,8 +369,7 @@ void wxCDMApplicationDescriptionPanel::OnBtnOpenMain(wxCommandEvent& event) wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LISTBOX_SELECTED); - int MId = this->application->GetMainFile()->GetId(); - newEvent->SetInt(MId); + newEvent->SetClientData(this->application->GetMainFile()); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); @@ -391,8 +387,7 @@ void wxCDMApplicationDescriptionPanel::OnMainMouseEnter(wxMouseEvent& event) if(this->application->GetMainFile() != NULL) { - int MId = this->application->GetMainFile()->GetId(); - newEvent->SetInt(MId); + newEvent->SetClientData(this->application->GetMainFile()); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); } @@ -405,8 +400,7 @@ void wxCDMApplicationDescriptionPanel::OnMainMouseExit(wxMouseEvent& event) if(this->application->GetMainFile() != NULL) { - int MId = this->application->GetMainFile()->GetId(); - newEvent->SetInt(MId); + newEvent->SetClientData(this->application->GetMainFile()); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); }