]> Creatis software - creaMaracasVisu.git/blob - lib/maracasVisuLib/src/interface/wxWindows/widgets/creaButtonContainer/view/groupManager.h
ab69ab4cbf29888a617d143672941f41f8fa2925
[creaMaracasVisu.git] / lib / maracasVisuLib / src / interface / wxWindows / widgets / creaButtonContainer / view / groupManager.h
1 /*# ---------------------------------------------------------------------
2 #
3 # Copyright (c) CREATIS (Centre de Recherche en Acquisition et Traitement de l'Image
4 #                        pour la Sant�)
5 # Authors : Eduardo Davila, Frederic Cervenansky, Claire Mouton
6 # Previous Authors : Laurent Guigues, Jean-Pierre Roux
7 # CreaTools website : www.creatis.insa-lyon.fr/site/fr/creatools_accueil
8 #
9 #  This software is governed by the CeCILL-B license under French law and
10 #  abiding by the rules of distribution of free software. You can  use,
11 #  modify and/ or redistribute the software under the terms of the CeCILL-B
12 #  license as circulated by CEA, CNRS and INRIA at the following URL
13 #  http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
14 #  or in the file LICENSE.txt.
15 #
16 #  As a counterpart to the access to the source code and  rights to copy,
17 #  modify and redistribute granted by the license, users are provided only
18 #  with a limited warranty  and the software's author,  the holder of the
19 #  economic rights,  and the successive licensors  have only  limited
20 #  liability.
21 #
22 #  The fact that you are presently reading this means that you have had
23 #  knowledge of the CeCILL-B license and that you accept its terms.
24 # ------------------------------------------------------------------------ */
25
26 /*!
27  * @file groupManager.h
28  * @brief This contains the GroupManager class
29  * @author Diego CACERES (diego.caceres[AT]creatis.insa-lyon.fr)
30  * @date  2011-06-02
31  */
32
33 #ifndef GROUPMANAGER_H
34 #define GROUPMANAGER_H
35
36 #include <wx/sizer.h>
37 #include <wx/button.h>
38 #include <wx/stattext.h>
39
40 #include <list>
41 #include <iostream>
42 #include <exception>
43
44 #include "buttonManager.h"
45 #include "buttonGroup.h"
46 #include "listGroup.h"
47
48 /*!     @namespace <creaButtonContainer>
49  *      @brief Contains the creaButtonContainer library included in creaMaracasVisu.
50  */
51 namespace creaButtonContainer
52 {
53         /*! @namespace <creaButtonContainer::view>
54          *      @brief Contains the implementation of the view in creaButtonContainer library.
55          *      @see <a href="http://en.wikipedia.org/wiki/Model-view-controller">MVC Software Architecture</a>
56          */
57         namespace view
58         {
59                 /*! @class GroupManager groupManager.h "groupManager.h"
60                  *      @brief This class contains the GroupManager.
61                  *  @details This class describes a wxFlexGridSizer with the group manager.
62                  *  @see <a href="http://docs.wxwidgets.org/stable/wx_wxflexGridSizer.html">wxFlexGridSizer</a>
63                  */
64                 class GroupManager : public wxFlexGridSizer
65                 {
66                         public:
67                                 //typedef definition
68                                 // ----------------------------------------------------------------------------------
69                                 /*!     @typedef creaButtonContainer::view::ButtonGroup ButtonGroup;
70                                  *      @brief Defines the ButtonGroup type.
71                                  */
72                                 typedef creaButtonContainer::view::ButtonGroup ButtonGroup;
73                                 // ----------------------------------------------------------------------------------
74                                 /*!     @typedef wxButton ExpansionButton;
75                                  *      @brief Defines the ExpansionButton type.
76                                  */
77                                 typedef wxButton ExpansionButton;
78                                 // ----------------------------------------------------------------------------------
79                                 //MLER
80                                 //typedef creaButtonContainer::view::ListGroup ListGroup;
81
82                                 //end of typedef definition.
83                         public:
84                                 // ----------------------------------------------------------------------------------
85                                 /*! @fn GroupManager( wxWindow* parent, ButtonGroup* buttonGroup );
86                                  *      @brief This is the parameterized constructor.
87                                  *      @param parent The wxWindow* parent
88                                  *      @param buttonGroup The pointer to the ButtonGroup.
89                                  */
90                                 GroupManager( wxWindow* parent, ButtonGroup* buttonGroup );
91                                 // ----------------------------------------------------------------------------------
92
93                                 //MLER
94                                 //GroupManager( wxWindow* parent, ListGroup* listGroup );
95                                 /*! @fn ~GroupManager( );
96                                  *  @brief This is the destructor.
97                                 */
98                                 virtual
99                                 ~GroupManager( );
100                                 // ----------------------------------------------------------------------------------
101                                 /*! @fn GetButtonID( );
102                                  *  @brief This method returns the Button ID.
103                                  *  @return
104                                  */
105                                 long
106                                 GetButtonID( );
107                                 // ----------------------------------------------------------------------------------
108                                 /*! @fn GetButton( );
109                                  *      @brief This method returns the expansion button.
110                                  * @return
111                                  */
112                                 ExpansionButton*
113                                 GetButton( );
114                                 // ----------------------------------------------------------------------------------
115                                 /*! @fn GetButtonManager( );
116                                  *      @brief This method returns the manager of the buttons.
117                                  *      @return
118                                  */
119                                 ButtonManager*
120                                 GetButtonManager( );
121                                 // ----------------------------------------------------------------------------------
122                                 /*! @fn SetButtonID( long id );
123                                  *      @brief This method sets the ID of the expansion button.
124                                  * @param id
125                                  */
126                                 void
127                                 SetButtonID( long id );
128                                 // ----------------------------------------------------------------------------------
129                                 /*! @fn SetButton( ExpansionButton* button );
130                                  *      @brief This method sets the expansion button.
131                                  * @param button
132                                  */
133                                 void
134                                 SetButton( ExpansionButton* button );
135                                 // ----------------------------------------------------------------------------------
136                                 /*! @fn SetButtonManager( ButtonManager* manager );
137                                  *      @brief This method Sets the ButtonManager
138                                  * @param manager A pointer with the manager.
139                                  */
140                                 void
141                                 SetButtonManager( ButtonManager* manager );
142                                 // ----------------------------------------------------------------------------------
143                                 /*! @fn HideSubPanel( bool hide );
144                                  *      @brief This method hides the subPanel (Hides the buttons).
145                                  * @param hide True if you need to hide the buttons.
146                                  */
147                                 void
148                                 HideSubPanel( bool hide );
149
150                         private:
151                                 long m_IDExpButton; //!<ID of "+""-" expansion button.
152                                 ExpansionButton* m_ExpansionButton; //!<The expansion button.
153                                 ButtonManager* m_ButtonManager; //!<The button manager.
154
155
156
157                 };
158         }//ecapseman
159 }//ecapseman
160
161 #endif // GROUPMANAGER_H