X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FcreaDevManagerLib%2FwxCDMBlackBoxHelpDialog.cpp;h=16f436df18fba6f1397f5606ae1bafdd9996d202;hb=f10df58dfa9c4d8489fe35f57f796bcf37e5f9b4;hp=480e9d04b817f73b5b275817e7921a85f774efd2;hpb=b8ae511b1e62c48bf4a418a13812d3ada5063550;p=crea.git diff --git a/lib/creaDevManagerLib/wxCDMBlackBoxHelpDialog.cpp b/lib/creaDevManagerLib/wxCDMBlackBoxHelpDialog.cpp index 480e9d0..16f436d 100644 --- a/lib/creaDevManagerLib/wxCDMBlackBoxHelpDialog.cpp +++ b/lib/creaDevManagerLib/wxCDMBlackBoxHelpDialog.cpp @@ -105,9 +105,12 @@ void wxCDMBlackBoxHelpDialog::CreateControls() "If you don't understand how this inputs and outputs are used, try looking at the sample black boxes available " "in the sample package, which is shipped with every new project.\n" "Also, don't forget to include the libraries your boxes use in the header and implementation files. They should " - "also be pointed and included in the package's directory CMakeLists.txt file and the project's directory " - "CMakeLists.txt file. Again, please take a look at the sample package and its boxes to see how to include libraries " - "in order to use them in the boxes.\n" + "also be pointed and included in the package's directory CMakeLists.txt file by uncommenting the \"SET\" commands " + "for third party libraries or by including the library name inside the \"SET(${BBTK_PACKAGE_NAME}_LIBS\"command " + "and its path inside the \"SET(${BBTK_PACKAGE_NAME}_INCLUDE_DIRS\" command for custom libraries. You must also " + "include the package your black box is in by including the command \"ADD_SUBDIRECTORY([packageName])\" in the " + "project's directory CMakeLists.txt file. Again, please take a look at the sample package and its boxes to see " + "how to include libraries in order to use them in the boxes.\n" "\n" "You can easily edit the CMakeLists files previously mentioned by clicking on the following buttons."), wxDefaultPosition, @@ -155,12 +158,11 @@ void wxCDMBlackBoxHelpDialog::OnCMakeLists(wxCommandEvent& event) if(!((modelCDMPackage*)node)->OpenCMakeListsFile(result)) wxMessageBox(crea::std2wx(*result),_T("Open CMakeLists File - Error!"),wxOK | wxICON_ERROR); - wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LIST_ITEM_DESELECTED); + wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LISTBOX_SELECTED); if(((modelCDMPackage*)node)->GetCMakeLists() != NULL) { - int CMId = ((modelCDMPackage*)node)->GetCMakeLists()->GetId(); - newEvent->SetInt(CMId); + newEvent->SetClientData(((modelCDMPackage*)node)->GetCMakeLists()); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); } @@ -182,12 +184,11 @@ void wxCDMBlackBoxHelpDialog::OnCMakeLists(wxCommandEvent& event) if(!((modelCDMProject*)node)->OpenCMakeListsFile(result)) wxMessageBox(crea::std2wx(*result),_T("Open CMakeLists File - Error!"),wxOK | wxICON_ERROR); - wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LIST_ITEM_DESELECTED); + wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LISTBOX_SELECTED); if(((modelCDMProject*)node)->GetCMakeLists() != NULL) { - int CMId = ((modelCDMProject*)node)->GetCMakeLists()->GetId(); - newEvent->SetInt(CMId); + newEvent->SetClientData(((modelCDMProject*)node)->GetCMakeLists()); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); } @@ -210,12 +211,11 @@ void wxCDMBlackBoxHelpDialog::OnCMakeListsEnter(wxMouseEvent& event) } if (node != NULL) { - wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LIST_ITEM_SELECTED); + wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LISTBOX_DOUBLECLICKED); if(((modelCDMPackage*)node)->GetCMakeLists() != NULL) { - int CMId = ((modelCDMPackage*)node)->GetCMakeLists()->GetId(); - newEvent->SetInt(CMId); + newEvent->SetClientData(((modelCDMPackage*)node)->GetCMakeLists()); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); } @@ -230,12 +230,11 @@ void wxCDMBlackBoxHelpDialog::OnCMakeListsEnter(wxMouseEvent& event) } if (node != NULL) { - wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LIST_ITEM_SELECTED); + wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LISTBOX_DOUBLECLICKED); if(((modelCDMProject*)node)->GetCMakeLists() != NULL) { - int CMId = ((modelCDMProject*)node)->GetCMakeLists()->GetId(); - newEvent->SetInt(CMId); + newEvent->SetClientData(((modelCDMProject*)node)->GetCMakeLists()); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); } @@ -255,12 +254,11 @@ void wxCDMBlackBoxHelpDialog::OnCMakeListsExit(wxMouseEvent& event) } if (node != NULL) { - wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LIST_ITEM_DESELECTED); + wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LISTBOX_SELECTED); if(((modelCDMPackage*)node)->GetCMakeLists() != NULL) { - int CMId = ((modelCDMPackage*)node)->GetCMakeLists()->GetId(); - newEvent->SetInt(CMId); + newEvent->SetClientData(((modelCDMPackage*)node)->GetCMakeLists()); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); } @@ -275,12 +273,11 @@ void wxCDMBlackBoxHelpDialog::OnCMakeListsExit(wxMouseEvent& event) } if (node != NULL) { - wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LIST_ITEM_DESELECTED); + wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LISTBOX_SELECTED); if(((modelCDMProject*)node)->GetCMakeLists() != NULL) { - int CMId = ((modelCDMProject*)node)->GetCMakeLists()->GetId(); - newEvent->SetInt(CMId); + newEvent->SetClientData(((modelCDMProject*)node)->GetCMakeLists()); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); }