X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FcreaDevManagerLib%2FwxCDMPackageManagerHelpDialog.cpp;h=6af683d1d26f4324859a5eb0f5dc272c6803cd22;hb=94511d0d24fe76a082b14afeab79bcaf0d1ecf13;hp=fe722724fb1a16651e6312fad079fb4ae5b2f4b4;hpb=82535c727c13786bc29fc0f0e73aca927d77b8fe;p=crea.git diff --git a/lib/creaDevManagerLib/wxCDMPackageManagerHelpDialog.cpp b/lib/creaDevManagerLib/wxCDMPackageManagerHelpDialog.cpp index fe72272..6af683d 100644 --- a/lib/creaDevManagerLib/wxCDMPackageManagerHelpDialog.cpp +++ b/lib/creaDevManagerLib/wxCDMPackageManagerHelpDialog.cpp @@ -90,32 +90,34 @@ void wxCDMPackageManagerHelpDialog::CreateControls() this, wxID_ANY, crea::std2wx( + "Packages contain black boxes, which allow to work modularly with other boxes. This boxes can use the functions " + "present in your libraries and expose them to work in a BBTK-fashion.\n" + "\n" "In the package manager you can view a list of the available packages in the current project, as well as create " "new packages. Remember that any package you make must be included in the CMakeLists file. You can do that by " - "clicking on the \"Edit CMakeLists File\" button and include the desired packages at the end of the file. You " - "should also include the libraries you are using on your black boxes in this file.\n" - "\n" - "Select an action or click Close to continue working on the project."), + "clicking on the \"Edit CMakeLists File\" button in the package manager section and include the desired packages " + "at the end of the file. You should also include in this file those libraries your black boxes located in this " + "package use."), wxDefaultPosition, wxDefaultSize, wxALIGN_LEFT ); v_sizer1->Add(instruction, 0,wxEXPAND | wxALL, 5); - wxFlexGridSizer* formItems = new wxFlexGridSizer(1,2,9,15); - - wxButton* createPackageBtn = new wxButton(this, ID_BUTTON_CREATE_PACKAGE, wxT("Create a Package")); - wxButton* editCMakeBtn= new wxButton(this, ID_BUTTON_EDIT_CMAKELISTSFILE, wxT("Edit the CMakeLists File")); - editCMakeBtn->Connect(wxEVT_ENTER_WINDOW, (wxObjectEventFunction)(wxEventFunction)(wxMouseEventFunction)&wxCDMPackageManagerHelpDialog::OnEditCMakeMouseEnter,NULL,this); - editCMakeBtn->Connect(wxEVT_LEAVE_WINDOW, (wxObjectEventFunction)(wxEventFunction)(wxMouseEventFunction)&wxCDMPackageManagerHelpDialog::OnEditCMakeMouseExit,NULL,this); - - formItems->Add(createPackageBtn, 1, wxALIGN_CENTER); - formItems->Add(editCMakeBtn, 1, wxALIGN_CENTER); - - formItems->AddGrowableCol(0,1); - formItems->AddGrowableCol(1,1); - - v_sizer1->Add(formItems, 1, wxEXPAND | wxALL, 15); +// wxFlexGridSizer* formItems = new wxFlexGridSizer(1,2,9,15); +// +// wxButton* createPackageBtn = new wxButton(this, ID_BUTTON_CREATE_PACKAGE, wxT("Create a Package")); +// wxButton* editCMakeBtn= new wxButton(this, ID_BUTTON_EDIT_CMAKELISTSFILE, wxT("Edit the CMakeLists File")); +// editCMakeBtn->Connect(wxEVT_ENTER_WINDOW, (wxObjectEventFunction)(wxEventFunction)(wxMouseEventFunction)&wxCDMPackageManagerHelpDialog::OnEditCMakeMouseEnter,NULL,this); +// editCMakeBtn->Connect(wxEVT_LEAVE_WINDOW, (wxObjectEventFunction)(wxEventFunction)(wxMouseEventFunction)&wxCDMPackageManagerHelpDialog::OnEditCMakeMouseExit,NULL,this); +// +// formItems->Add(createPackageBtn, 1, wxALIGN_CENTER); +// formItems->Add(editCMakeBtn, 1, wxALIGN_CENTER); +// +// formItems->AddGrowableCol(0,1); +// formItems->AddGrowableCol(1,1); +// +// v_sizer1->Add(formItems, 1, wxEXPAND | wxALL, 15); v_sizer1->Add(new wxCheckBox(this, ID_CHECKBOX_DISABLE_HELP, wxT("&Disable help")), 0, wxALIGN_RIGHT | wxRIGHT, 10); @@ -155,12 +157,11 @@ void wxCDMPackageManagerHelpDialog::OnEditCMake(wxCommandEvent& event) void wxCDMPackageManagerHelpDialog::OnEditCMakeMouseEnter(wxMouseEvent& event) { - wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LIST_ITEM_SELECTED); + wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LISTBOX_DOUBLECLICKED); if(packageManager->GetProject()->GetCMakeLists() != NULL) { - int CMId = packageManager->GetProject()->GetCMakeLists()->GetId(); - newEvent->SetInt(CMId); + newEvent->SetClientData(packageManager->GetProject()->GetCMakeLists()); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); } @@ -169,12 +170,11 @@ void wxCDMPackageManagerHelpDialog::OnEditCMakeMouseEnter(wxMouseEvent& event) void wxCDMPackageManagerHelpDialog::OnEditCMakeMouseExit(wxMouseEvent& event) { - wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LIST_ITEM_DESELECTED); + wxCommandEvent* newEvent = new wxCommandEvent(wxEVT_COMMAND_LISTBOX_SELECTED); if(packageManager->GetProject()->GetCMakeLists() != NULL) { - int CMId = packageManager->GetProject()->GetCMakeLists()->GetId(); - newEvent->SetInt(CMId); + newEvent->SetClientData(packageManager->GetProject()->GetCMakeLists()); newEvent->SetId(0); wxPostEvent(this->GetParent(), *newEvent); }