1 /***************************************************************
2 * Name: ButtonGroup.cxx
3 * Purpose: Implements ButtonGroup.h
4 * Author: Diego CACERES (diego.caceres[AT]creatis.insa-lyon.fr)
6 * Copyright: Diego CACERES (http://www.creatis.insa-lyon.fr/~caceres/)
8 **************************************************************/
10 #include "buttonGroup.h"
12 namespace creaButtonContainer
16 /*typedef creaButtonContainer::view::Button Button;
17 typedef std::map< long, Button* > ButtonContainer;
18 typedef std::list< long > IdButtonContainer;*/
19 //--------------------------------------------------
20 ButtonGroup::ButtonGroup( wxStaticText* groupName,
21 ButtonContainer cartoButtons )
23 this->m_GroupName = groupName;
24 this->m_Buttons = cartoButtons;
27 //--------------------------------------------------
28 ButtonGroup::~ButtonGroup( )
31 //--------------------------------------------------
33 ButtonGroup::GetButtonContainer( )
35 return ( this->m_Buttons );
37 //--------------------------------------------------
39 ButtonGroup::GetGroupName( )
41 return ( this->m_GroupName );
43 //--------------------------------------------------
45 ButtonGroup::GetButtonIdContainer( )
47 IdButtonContainer idContainer;
48 for( ButtonContainer::iterator it = this->m_Buttons.begin( ); it
49 != this->m_Buttons.end( ); ++it )
50 idContainer.push_back( (*it).first );
51 return ( idContainer );
53 //--------------------------------------------------
55 ButtonGroup::GetButton( long id )
57 return( this->m_Buttons[id] );