1 /***************************************************************
2 * Name: buttonContainerSettings.h
3 * Purpose: It is the ButtonGroupSettings
4 * Author: Diego CACERES (diego.caceres[AT]creatis.insa-lyon.fr)
6 * Copyright: Diego CACERES (http://www.creatis.insa-lyon.fr/~caceres/)
8 **************************************************************/
10 #ifndef BUTTONCONTAINERSETTINGS_H_
11 #define BUTTONCONTAINERSETTINGS_H_
18 #include "structButtonContainerSettings.h"
19 #include "containerSettings.h"
22 namespace creaPanelButtonContainer
24 typedef creaButtonContainer::model::TFunctor TFunctor;
25 typedef creaButtonContainer::model::ContainerSettings ButtonGroupSettings;
26 typedef wxPanel* PanelButton;
27 //First is the button description, Second FunctionEventType
28 typedef std::pair< std::string, PanelButton > ActionButton;
29 //First is the ButtonName and Second is the ImageIconPath
30 typedef std::pair< std::string, std::string > ButtonInfo;
31 typedef std::pair< ButtonInfo*, ActionButton* > ButtonPair;
32 typedef std::list< std::string > KeyMapList;
33 typedef std::list< ButtonPair* > ButtonList;
34 typedef std::map< std::string, ButtonList > ButtonGroupMap;
35 typedef std::vector< BCSettingsStruct* > BCStructVectorType;
36 class ButtonContainerSettings
39 ButtonContainerSettings( );
41 ~ButtonContainerSettings( );
43 GetButtonGroupContainer( );
47 GetPanelButton( const std::string &buttonName );
49 GetButtonGroupSettings( TFunctor* functor );
51 SetButtonGroupContainer( ButtonGroupMap m_ButtonGroupContainer );
53 SetGroupNameList( KeyMapList m_GroupNameList );
55 AddButton( const std::string &groupName, const std::string &buttonName,
56 const std::string &iconpath, const std::string &buttonDescription,
59 AddButton( BCSettingsStruct* info );
62 AddButtons( BCStructVectorType infoList );
65 ButtonGroupMap m_ButtonGroupContainer;
66 KeyMapList m_GroupNameList;
69 #endif /* BUTTONCONTAINERSETTINGS_H_ */