-/***************************************************************
- * Name: ButtonManager.h
- * Purpose: Defines the button group container
- * Author: Diego CACERES (diego.caceres[AT]creatis.insa-lyon.fr)
- * Modified: 2011-05-09
- * Copyright: Diego CACERES (http://www.creatis.insa-lyon.fr/~caceres/)
- * License:
- **************************************************************/
+/*!
+ * @file buttonManager.h
+ * @brief This contains the ButtonManager class.
+ * @author Diego CACERES (diego.caceres[AT]creatis.insa-lyon.fr)
+ * @date 2011-06-02
+ */
#ifndef CARTOBUTTONCONTAINER_H
#define CARTOBUTTONCONTAINER_H
#include <wx/bmpbuttn.h>
#include <wx/stattext.h>
#include <wx/string.h>
+
#include <map>
+#include <exception>
+
#include "button.h"
#include "buttonGroup.h"
+/*! @namespace <creaButtonContainer>
+ * @brief Contains the creaButtonContainer library included in creaMaracasVisu.
+ */
namespace creaButtonContainer
{
+ /*! @namespace <creaButtonContainer::view>
+ * @brief Contains the implementation of the view in creaButtonContainer library.
+ * @see <a href="http://en.wikipedia.org/wiki/Model-view-controller">MVC Software Architecture</a>
+ */
namespace view
{
- /**
- Class Description:
- **/
+ /*! @class ButtonManager buttonManager.h "buttonManager.h"
+ * @brief This class contains the ButtonManager view.
+ * @details This class describes a wxFlexGridSizer with the button manager.
+ * @see <a href="http://docs.wxwidgets.org/stable/wx_wxflexGridSizer.html">wxFlexGridSizer</a>
+ */
class ButtonManager : public wxFlexGridSizer
{
public:
+ //typedef definition.
+ // ----------------------------------------------------------------------------------
+ /*! @typedef creaButtonContainer::view::Button Button;
+ * @brief Defines the Button type.
+ */
typedef creaButtonContainer::view::Button Button;
+ // ----------------------------------------------------------------------------------
+ /*! @typedef creaButtonContainer::view::ButtonGroup ButtonGroup;
+ * @brief Defines the ButtonGroup type.
+ */
typedef creaButtonContainer::view::ButtonGroup ButtonGroup;
+ // ----------------------------------------------------------------------------------
+ /*! @typedef std::map< long, Button* > ButtonContainer;
+ * @brief Defines the ButtonContainer type.
+ */
typedef std::map< long, Button* > ButtonContainer;
+ // ----------------------------------------------------------------------------------
+ //end of typedef definition.
public:
+ // ----------------------------------------------------------------------------------
+ /*! @fn ButtonManager( );
+ * @brief This is the default constructor.
+ * @exception std::bad_alloc
+ */
ButtonManager( );
+ // ----------------------------------------------------------------------------------
+ /*! @fn ButtonManager( ButtonGroup* buttonGroup );
+ * @brief This is the parameterized constructor
+ * @param buttonGroup The group of buttons.
+ */
ButtonManager( ButtonGroup* buttonGroup );
+ // ----------------------------------------------------------------------------------
+ /*! @fn ~ButtonManager( );
+ * @brief This is the destructor.
+ */
virtual
~ButtonManager( );
+ // ----------------------------------------------------------------------------------
+ /*! @fn SetGroupName( wxStaticText* groupName );
+ * @details Sets the groupName.
+ * @param groupName
+ */
void
SetGroupName( wxStaticText* groupName );
+ // ----------------------------------------------------------------------------------
+ /*! @fn ShowButtonManager( );
+ * @brief This method shows the ButtonManager
+ */
void
ShowButtonManager( );
+ // ----------------------------------------------------------------------------------
+ /*! @fn HideButtonManager( );
+ * @brief This method hides the ButtonManager.
+ * @exception std::bad_alloc
+ */
void
HideButtonManager( );
+ // ----------------------------------------------------------------------------------
private:
+ // ----------------------------------------------------------------------------------
+ /*! @fn SetButtonManager( ButtonContainer buttonContainer );
+ * @brief This method set the buttons and it is private.
+ * @param buttonContainer
+ */
void
SetButtonManager( ButtonContainer buttonContainer );
+ // ----------------------------------------------------------------------------------
private:
- wxStaticText* m_GroupName;
- wxGridSizer* m_GridSizer;
+ wxStaticText* m_GroupName; //!<The name of the group.
+ wxGridSizer* m_GridSizer; //!<The sizer that contains the buttons.
};
}//ecapseman
}//ecapseman