X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FmaracasVisuLib%2Fsrc%2Finterface%2FwxWindows%2Fwidgets%2FcreaButtonContainer%2Fview%2FlistWx.h;h=4b682c8ad5b47d978fbe53dad2ac0020dcad5367;hb=3c6c4d236dd41550927d9180688f40c127301431;hp=346552982ff271e6ceea3dc6ef2abb329f06a990;hpb=bbd33bbb0f352d14d7068d87fcd50e02341004a9;p=creaMaracasVisu.git diff --git a/lib/maracasVisuLib/src/interface/wxWindows/widgets/creaButtonContainer/view/listWx.h b/lib/maracasVisuLib/src/interface/wxWindows/widgets/creaButtonContainer/view/listWx.h index 3465529..4b682c8 100644 --- a/lib/maracasVisuLib/src/interface/wxWindows/widgets/creaButtonContainer/view/listWx.h +++ b/lib/maracasVisuLib/src/interface/wxWindows/widgets/creaButtonContainer/view/listWx.h @@ -28,83 +28,59 @@ //#include #include -#include #include -#include -//#include -#include -#include #include #include +#include -#include #include -#include "functor.h" -#include +#include +#include +#include "functor.h" #include "system.h" -#include "listConfig.h" -//#include "listConfigPanel.h" - -namespace creaButtonContainer { -namespace view { +namespace creaButtonContainer +{ -class ListWx: public wxPanel { -public: + namespace view + { - typedef creaButtonContainer::model::TFunctor TFunctor; - typedef std::map ItemsMap; - typedef creaButtonContainer::model::ListConfig ListConfig; + class ListWx: public wxPanel + { + public: -public: + typedef creaButtonContainer::model::TFunctor TFunctor; + typedef std::pair ListAction; + typedef std::vector ItemsVector; - ListWx(wxWindow* parent, wxWindowID id, ItemsMap iMap, TFunctor* functor); - ListWx(wxWindow* parent, wxWindowID id, ItemsMap iMap, TFunctor* functor, - std::string c); - // ---------------------------------------------------------------------------------- + public: - virtual - ~ListWx(); - // ---------------------------------------------------------------------------------- + ListWx(wxWindow* parent, wxWindowID id, ItemsVector iVector, + TFunctor* functor); + ListWx(wxWindow* parent, wxWindowID id, TFunctor* functor); - long - GetID(); + virtual + ~ListWx(); - void - FillList(); + void + ListEvent(wxCommandEvent& event); - void - ListEvent(wxCommandEvent& event); + void + SetFunctorEnabled(const bool& enabled); - ItemsMap - GetItemsMap(); + bool + IsFunctorEnabled() const; - TFunctor* - GetWxListFunctor(); + private: - void SetFunctorEnabled(const bool& enabled); + wxListBox* m_ListBox; - void AddItemToMap(std::string key, wxPanel* panel); + TFunctor* m_Functor; + bool m_FunctorEnabled; - void DeleteItemFromMap(std::string key); - - bool IsFunctorEnabled() const; - - wxListBox* - GetListBox() const; - - // ---------------------------------------------------------------------------------- -private: - ItemsMap m_itemsMap; //! - TFunctor* functor; - wxListBox* listBox; - wxFlexGridSizer* sizer; - wxButton* button; - bool m_functorEnabled; - ListConfig* m_listConfig; -}; -} //ecapseman + }; + } //ecapseman } //ecapseman #endif // LISTWX_H