fw4spl
IMenuBarLayoutManager.hpp
Go to the documentation of this file.
1 /* ***** BEGIN LICENSE BLOCK *****
2  * FW4SPL - Copyright (C) IRCAD, 2009-2016.
3  * Distributed under the terms of the GNU Lesser General Public License (LGPL) as
4  * published by the Free Software Foundation.
5  * ****** END LICENSE BLOCK ****** */
6 
15 #ifndef __FWGUI_LAYOUTMANAGER_IMENUBARLAYOUTMANAGER_HPP__
16 #define __FWGUI_LAYOUTMANAGER_IMENUBARLAYOUTMANAGER_HPP__
17 
18 #include <fwRuntime/ConfigurationElement.hpp>
19 
20 #include "fwGui/GuiBaseObject.hpp"
21 #include "fwGui/container/fwMenuBar.hpp"
22 #include "fwGui/container/fwMenu.hpp"
23 #include "fwGui/config.hpp"
24 
25 namespace fwGui
26 {
27 namespace layoutManager
28 {
29 
37 class FWGUI_CLASS_API IMenuBarLayoutManager : public ::fwGui::GuiBaseObject
38 {
39 public:
41 
42  typedef ::fwRuntime::ConfigurationElement::sptr ConfigurationType;
43  typedef std::string RegistryKeyType;
44 
45  FWGUI_API const static RegistryKeyType REGISTRY_KEY;
46 
48  FWGUI_API IMenuBarLayoutManager();
49 
51  FWGUI_API virtual ~IMenuBarLayoutManager();
52 
56  FWGUI_API virtual std::vector< ::fwGui::container::fwMenu::sptr > getMenus();
57 
82  FWGUI_API virtual void initialize( ConfigurationType configuration);
83 
89  FWGUI_API virtual void createLayout( ::fwGui::container::fwMenuBar::sptr parent ) = 0;
90 
95  FWGUI_API virtual void destroyLayout() = 0;
96 
97 
101  FWGUI_API virtual void menuIsVisible(::fwGui::container::fwMenu::sptr, bool isVisible) = 0;
102 
106  FWGUI_API virtual void menuIsEnabled(::fwGui::container::fwMenu::sptr, bool isEnabled) = 0;
107 
108 
109 protected:
110 
114  FWGUI_API virtual void destroyMenus();
115 
117  std::vector< ::fwGui::container::fwMenu::sptr > m_menus;
118 
120  std::vector< std::string > m_menuNames;
121 
122 };
123 
124 } // namespace layoutManager
125 } // namespace fwGui
126 
127 #endif /*__FWGUI_LAYOUTMANAGER_IMENUBARLAYOUTMANAGER_HPP__*/
128 
129 
#define fwCoreNonInstanciableClassDefinitionsMacro(_classinfo_)
Generate common code for Non Instanciable classes (Interfaces, Abstract classes, ...)
The namespace fwGui contains the base interface for IHM services.
Definition: SJobBar.hpp:23
STL namespace.
The namespace fwRuntime contains classes to manage bundle, configuration element, extension point in ...
Defines the menu bar layout manager for IHM.
Base class for all fwGui&#39;s classes.