]> Creatis software - creaMaracasVisu.git/blob
dffcdeb675ad933285a9f32987eef62c0c8441b7
[creaMaracasVisu.git] /
1 /*!
2  * @file PanelButtonContainer
3  * @brief This contains the ButtonContainerSettings class.
4  * @author Diego CACERES (diego.caceres[AT]creatis.insa-lyon.fr)
5  * @date  2011-06-02
6  */
7
8 #ifndef PANELBUTTONCONTAINER_H_
9 #define PANELBUTTONCONTAINER_H_
10
11 #include <wx/panel.h>
12 #include <wx/aui/aui.h>
13 #include <string>
14
15 #include "containerSettings.h"
16 #include "buttonContainerPanel.h"
17 #include "buttonContainerSettings.h"
18 #include "functor.h"
19
20 /*!     @namespace <creaPanelButtonContainer>
21  *      @brief Contains the creaPanelButtonContainer library included in creaMaracasVisu.
22  */
23 namespace creaPanelButtonContainer
24 {
25         /*! @class PanelButtonContainer panelButtonContainer.h "panelButtonContainer.h"
26          *      @brief This class contains the PanelButtonContainer. It derives from wxPanel.
27          *  @see <a href="http://docs.wxwidgets.org/stable/wx_wxpanel.html">wxPanel</a>
28          */
29         class PanelButtonContainer : public wxPanel
30         {
31                 public:
32                         //typedef definition.
33                         // ----------------------------------------------------------------------------------
34                         /*!     typedef creaPanelButtonContainer::ButtonContainerSettings ButtonContainerSettings;
35                          *      @brief Defines the ButtonContainerSettings type.
36                          */
37                         typedef creaPanelButtonContainer::ButtonContainerSettings
38                             ButtonContainerSettings;
39                         /*!     typedef creaButtonContainer::view::ButtonContainerPanel ButtonContainerPanel;
40                          *      @brief Defines the ButtonContainerPanel type.
41                          */
42                         typedef creaButtonContainer::view::ButtonContainerPanel
43                             ButtonContainerPanel;
44                         // ----------------------------------------------------------------------------------
45                         //end of typedef definition.
46                 public:
47                         // ----------------------------------------------------------------------------------
48                         /*! @fn PanelButtonContainer( wxWindow* parent, ButtonContainerSettings* bcSettings );
49                          *      @brief This is the parameterized constructor.
50                          *      @param parent The wxWindow pointer to parent
51                          *      @param bcSettings //The buttonContainerSettings
52                          */
53                         PanelButtonContainer( wxWindow* parent,
54                             ButtonContainerSettings* bcSettings );
55                         // ----------------------------------------------------------------------------------
56                         /*! @fn virtual PanelButtonContainer( );
57                          *      @brief This is the destructor.
58                          */
59                         virtual
60                         ~PanelButtonContainer( );
61                         // ----------------------------------------------------------------------------------
62                         /*! @fn void UpdatePanel( const std::string &buttonName );
63                          *  @brief This method Updates the m_ButtonPanel to a panel
64                          *  of the clicked button in creaButtonContainer.
65                          *      @param buttonName
66                          */
67                         void
68                         UpdatePanel( const std::string &buttonName );
69                         // ----------------------------------------------------------------------------------
70                         /*! @fn void GenericButtonEvent( const std::string &buttonName );
71                          *      @brief This method is the function that calls the panels contained in the buttons
72                          *      (in creaButtonContainer is the function contained in the functors to be called back.
73                          *      @param buttonName The name of the button
74                          */
75                         void
76                         GenericButtonEvent( const std::string &buttonName );
77                         // ----------------------------------------------------------------------------------
78                 private:
79                         //Settings
80                         ButtonContainerSettings* m_ButtonContainerSettings; //!<This is the buttonContainer settings.
81                         //Panel
82                         ButtonContainerPanel* m_ButtonContainerPanel; //!<This is the panel with de buttons (creaButtonContainer)
83                         wxAuiManager* m_AuiManager; //!<The AUI Manager for the panels.
84                         wxPanel* m_ButtonPanel; //!<This is the panel used to contain the panels of the buttons. (it changes with the buttonAction)
85                 DECLARE_EVENT_TABLE() //!<Event Table declaration.
86         };
87 }//ecapseman
88
89 #endif // PANELBUTTONCONTAINER_H_