X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FmaracasVisuLib%2Fsrc%2Finterface%2FwxWindows%2Fwidgets%2FcreaButtonContainer%2Fview%2FbuttonContainerPanel.h;h=86dd513fd4bb5f44f634174ea13b8d0a73090322;hb=47d49bceea4f93ff4f57c40596960d042171abb4;hp=65f3db3ccb8f9198d15cd9c24b182dcc6c1e7a18;hpb=f6c7b458a17b67950d1844d6a600683a99cb2b6d;p=creaMaracasVisu.git diff --git a/lib/maracasVisuLib/src/interface/wxWindows/widgets/creaButtonContainer/view/buttonContainerPanel.h b/lib/maracasVisuLib/src/interface/wxWindows/widgets/creaButtonContainer/view/buttonContainerPanel.h index 65f3db3..86dd513 100644 --- a/lib/maracasVisuLib/src/interface/wxWindows/widgets/creaButtonContainer/view/buttonContainerPanel.h +++ b/lib/maracasVisuLib/src/interface/wxWindows/widgets/creaButtonContainer/view/buttonContainerPanel.h @@ -1,8 +1,33 @@ +/*# --------------------------------------------------------------------- + # + # Copyright (c) CREATIS (Centre de Recherche en Acquisition et Traitement de l'Image + # pour la Sant�) + # Authors : Eduardo Davila, Frederic Cervenansky, Claire Mouton + # Previous Authors : Laurent Guigues, Jean-Pierre Roux + # CreaTools website : www.creatis.insa-lyon.fr/site/fr/creatools_accueil + # + # This software is governed by the CeCILL-B license under French law and + # abiding by the rules of distribution of free software. You can use, + # modify and/ or redistribute the software under the terms of the CeCILL-B + # license as circulated by CEA, CNRS and INRIA at the following URL + # http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html + # or in the file LICENSE.txt. + # + # As a counterpart to the access to the source code and rights to copy, + # modify and redistribute granted by the license, users are provided only + # with a limited warranty and the software's author, the holder of the + # economic rights, and the successive licensors have only limited + # liability. + # + # The fact that you are presently reading this means that you have had + # knowledge of the CeCILL-B license and that you accept its terms. + # ------------------------------------------------------------------------ */ + /*! * @file buttonContainerController.h * @brief This contains the ButtonContainerController class * @author Diego CACERES (diego.caceres[AT]creatis.insa-lyon.fr) - * @date 2011-05-19 + * @date 2011-06-02 */ #ifndef BUTTONCONTAINERPANEL_H @@ -11,8 +36,10 @@ #include #include #include + #include #include +#include #include "buttonGroup.h" #include "groupManager.h" @@ -33,8 +60,7 @@ namespace creaButtonContainer { /*! @class ButtonContainerController buttonContainerController.h "buttonContainerController.h" * @brief This class contains the ButtonContainerPanel controller. - * @details This class describes the button events, it derives from wxEvtHandler and it is the - * controller in the MVC. + * @details This class describes the button events, it derives from wxEvtHandler. * @see wxEvtHandler */ class ButtonContainerController; @@ -46,92 +72,114 @@ namespace creaButtonContainer */ namespace view { - class ButtonContainerPanel : public wxScrolledWindow + /*! @class ButtonContainerPanel buttonContainerPanel.h "buttonContainerPanel.h" + * @brief This class is the container of the creaButtonContainer. + * @details This class derives from wxScrolledWindow and manages the view of the buttonContainer. + * @bug The scrolled it doesn't work! (to be changed soon) + * @see wxScrolledWindow + */ + class ButtonContainerPanel: public wxScrolledWindow { public: //typedef definition - /*! @typedef creaButtonContainer::model::TFunctor TFunctor; - * @brief Defines the TFunctor type. + // ---------------------------------------------------------------------------------- + /*! @typedef creaButtonContainer::view::ButtonGroup ButtonGroup; + * @brief Defines the ButtonGroup type. */ typedef creaButtonContainer::view::ButtonGroup ButtonGroup; - /*! @typedef creaButtonContainer::model::TFunctor TFunctor; - * @brief Defines the TFunctor type. + // ---------------------------------------------------------------------------------- + /*! @typedef creaButtonContainer::view::GroupManager GroupManager; + * @brief Defines the GroupManager type. */ typedef creaButtonContainer::view::GroupManager GroupManager; - /*! @typedef creaButtonContainer::model::TFunctor TFunctor; - * @brief Defines the TFunctor type. + // ---------------------------------------------------------------------------------- + /*! @typedef std::list< ButtonGroup* > ButtonGroupList; + * @brief Defines the ButtonGroupList type. */ - typedef std::list< ButtonGroup* > ButtonGroupList; - /*! @typedef creaButtonContainer::model::TFunctor TFunctor; - * @brief Defines the TFunctor type. + typedef std::list ButtonGroupList; + // ---------------------------------------------------------------------------------- + /*! @typedef std::map< long, GroupManager* > GroupManagerList; + * @brief Defines the GroupManagerList type. */ - typedef std::map< long, GroupManager* > GroupManagerList; - /*! @typedef creaButtonContainer::model::TFunctor TFunctor; - * @brief Defines the TFunctor type. + typedef std::map GroupManagerList; + // ---------------------------------------------------------------------------------- + /*! @typedef wxFlexGridSizer Sizer; + * @brief Defines the Sizer type. */ typedef wxFlexGridSizer Sizer; - /*! @typedef creaButtonContainer::model::TFunctor TFunctor; - * @brief Defines the TFunctor type. + // ---------------------------------------------------------------------------------- + /*! @typedef std::list< long > KeyList; + * @brief Defines the KeyList type. */ - typedef std::list< long > KeyList; - /*! @typedef creaButtonContainer::model::TFunctor TFunctor; - * @brief Defines the TFunctor type. + typedef std::list KeyList; + // ---------------------------------------------------------------------------------- + /*! @typedef creaButtonContainer::model::ContainerSettings ButtonGroupSettings; + * @brief Defines the ButtonGroupSettings type. */ - typedef creaButtonContainer::model::ContainerSettings - ButtonGroupSettings; - /*! @typedef creaButtonContainer::model::TFunctor TFunctor; - * @brief Defines the TFunctor type. + typedef creaButtonContainer::model::ContainerSettings ButtonGroupSettings; + // ---------------------------------------------------------------------------------- + /*! @typedef creaButtonContainer::model::ButtonGroupFactory ButtonGroupFactory; + * @brief Defines the ButtonGroupFactory type. */ - typedef creaButtonContainer::model::ButtonGroupFactory - ButtonGroupFactory; - /*! @typedef creaButtonContainer::model::TFunctor TFunctor; - * @brief Defines the TFunctor type. + typedef creaButtonContainer::model::ButtonGroupFactory ButtonGroupFactory; + // ---------------------------------------------------------------------------------- + /*! creaButtonContainer::controller::ButtonContainerController BCController; + * @brief Defines the BCController type. */ - typedef creaButtonContainer::controller::ButtonContainerController - BCController; + typedef creaButtonContainer::controller::ButtonContainerController BCController; + + // ---------------------------------------------------------------------------------- //end of typedef definition public: /*! @fn ButtonContainerPanel( wxWindow* parent, ButtonGroupSettings* settings ); - * - * @param parent - * @param settings + * @brief This is the parameterized constructor. + * @param parent wxWindow pointer to parent. + * @param settings ButtonGroupSettings Pointer to button container settings. */ - ButtonContainerPanel( wxWindow* parent, ButtonGroupSettings* settings ); + ButtonContainerPanel(wxWindow* parent, ButtonGroupSettings* settings); // ---------------------------------------------------------------------------------- /*! @fn ~ButtonContainerPanel( ); - * + * @brief This is the destructor. */ virtual - ~ButtonContainerPanel( ); + ~ButtonContainerPanel(); // ---------------------------------------------------------------------------------- /*! @fn SetGroupContainer( ButtonGroupList groupContainer ); - * + * @brief This method sets the settings to the container. * @param groupContainer */ void - SetGroupContainer( ButtonGroupList groupContainer ); + SetButtonGroupContainer(ButtonGroupList groupContainer); // ---------------------------------------------------------------------------------- /*! @fn PanelInit( ); - * + * This method initializes the panel. + * @exception std::bad_alloc */ void - PanelInit( ); + PanelInit(); + // ---------------------------------------------------------------------------------- + + //void + //SetListGroupContainer(ListGroupList groupContainer ); // ---------------------------------------------------------------------------------- /*! @fn FitSizer( ); - * + * This method fits and organizes the sizer. */ void - FitSizer( ); + FitSizer(); // ---------------------------------------------------------------------------------- public: friend class creaButtonContainer::controller::ButtonContainerController; private: - GroupManagerList m_GroupManagerList; - ButtonGroupList m_ButtonGroupList; - BCController* m_ButtonCController; - Sizer* m_Sizer; + GroupManagerList m_GroupManagerList; //!