|
fw4spl
|
Defines the toolBar registrar for IHM. More...
#include <ToolBarRegistrar.hpp>
Inheritance diagram for fwGui::registrar::ToolBarRegistrar:
Collaboration diagram for fwGui::registrar::ToolBarRegistrar:Public Types | |
| typedef std::vector< ::fwGui::IMenuItemCallback::sptr > | CallbacksType |
Public Types inherited from fwGui::GuiBaseObject | |
| typedef ::fwGui::factory::Key | Key |
Public Member Functions | |
| virtual bool | isA (const std::string &type) const override |
| FWGUI_API | ToolBarRegistrar (const std::string &sid) |
| Constructor. | |
| virtual FWGUI_API | ~ToolBarRegistrar () |
| Destructor. Do nothing. | |
| virtual FWGUI_API::fwGui::container::fwToolBar::sptr | getParent () |
| Return the parent container. | |
| virtual FWGUI_API::fwGui::container::fwMenuItem::sptr | getFwMenuItem (std::string actionSid, std::vector< ::fwGui::container::fwMenuItem::sptr > menuItems) |
| Return the fwMenuItem associated with the actionSid. More... | |
| virtual FWGUI_API void | initialize (::fwRuntime::ConfigurationElement::sptr configuration) |
| Initialize registry managers. More... | |
| virtual FWGUI_API void | manage (std::vector< ::fwGui::container::fwMenuItem::sptr > toolBarItems) |
| manages action service associated with menuItem of toolbar. More... | |
| virtual FWGUI_API void | manage (std::vector< ::fwGui::container::fwMenu::sptr > toolBarItems) |
| manages menu service associated with item of toolbar. More... | |
| virtual FWGUI_API void | manage (std::vector< ::fwGui::container::fwContainer::sptr > toolBarItems) |
| manages editor service associated with item of toolbar. More... | |
| virtual FWGUI_API void | unmanage () |
| Stopping toolBar items manager. All services managed in local toolBar items will be stopped. | |
| virtual FWGUI_API void | onItemAction () |
| This method is called when an action is clicked. | |
| virtual CallbacksType | getCallbacks () |
| Returns callbacks associate with toolBar items. | |
Public Member Functions inherited from fwGui::GuiBaseObject | |
Public Member Functions inherited from fwCore::BaseObject | |
Static Public Member Functions | |
| static bool | isTypeOf (const std::string &type) |
Static Public Member Functions inherited from fwGui::GuiBaseObject | |
| static bool | isTypeOf (const std::string &type) |
| static const std::string & | classname () |
| return full object's classname with its namespace, i.e. fwCore::BaseObject | |
Static Public Member Functions inherited from fwCore::BaseObject | |
| static bool | isTypeOf (const std::string &type) |
| static const std::string & | leafClassname () |
| return object's classname without its namespace, i.e. BaseObject | |
| static const std::string & | classname () |
| return object's classname without its namespace, i.e. BaseObject | |
Protected Attributes | |
| SIDToolBarMapType | m_actionSids |
| All toolBar services ID managed and associated with pair containing: action's index vector and boolean describing if is started by the manager. | |
| SIDToolBarMapType | m_menuSids |
| All toolBar services ID managed and associated with pair containing: menus index vector and boolean describing if is started by the manager. | |
| SIDToolBarMapType | m_editorSids |
| All toolBar services ID managed and associated with pair containing: editors index vector and boolean describing if is started by the manager. | |
| WIDToolBarMapType | m_editorWids |
| All toolBar servicesID managed (and associated with subViews index vector). | |
| std::string | m_sid |
| Main service ID associate with this ToolBarRegistrar. | |
| CallbacksType | m_callbacks |
| Callback associate with toolBar items. | |
Friends | |
| template<class , class , class > | |
| class | ::fwTools::ClassFactory |
| class | ::fwTools::Factory |
Demangling methods | |
| virtual const std::string & | getLeafClassname () const override |
| return object's classname without its namespace, i.e. BaseObject | |
| virtual const std::string & | getClassname () const override |
| return full object's classname with its namespace, i.e. fwCore::BaseObject | |
| static const std::string & | leafClassname () |
| return object's classname without its namespace, i.e. BaseObject | |
| static const std::string & | classname () |
| return object's classname without its namespace, i.e. BaseObject | |
Additional Inherited Members | |
Protected Member Functions inherited from fwGui::GuiBaseObject | |
| GuiBaseObject () | |
| virtual | ~GuiBaseObject () |
Defines the toolBar registrar for IHM.
Definition at line 28 of file ToolBarRegistrar.hpp.
|
virtual |
Return the fwMenuItem associated with the actionSid.
| actionSid | sid of the action service |
| menuItems | vector containing the fwMenuItem manages by this registrar. |
Definition at line 46 of file ToolBarRegistrar.cpp.
References m_actionSids, and SLM_ASSERT.
|
virtual |
Initialize registry managers.
Example of configuration
This method analyzes the registry section of the configuration.
Definition at line 56 of file ToolBarRegistrar.cpp.
References m_actionSids, m_callbacks, m_editorSids, m_editorWids, m_menuSids, OSLM_ASSERT, and SLM_ASSERT.
|
virtual |
manages action service associated with menuItem of toolbar.
Register the menuItem containers for the associated services. Start the services if start=yes.
If a menuItem has attribut start="no", the associated action won't be started and the menuItem will be disabled. If a menuItem has attribut start="yes", two possibilities:
Definition at line 150 of file ToolBarRegistrar.cpp.
References fwGui::GuiRegistry::actionServiceStarting(), fwGui::GuiRegistry::actionServiceStopping(), fwTools::fwID::exist(), fwServices::get(), m_actionSids, m_sid, OSLM_ASSERT, and fwGui::GuiRegistry::registerActionSIDToParentSID().
Here is the call graph for this function:
|
virtual |
manages menu service associated with item of toolbar.
Register the menu containers for the associated services. Start the services if start=yes.
Definition at line 183 of file ToolBarRegistrar.cpp.
References fwTools::fwID::exist(), m_menuSids, OSLM_ASSERT, and fwGui::GuiRegistry::registerSIDMenu().
Here is the call graph for this function:
|
virtual |
manages editor service associated with item of toolbar.
Register the containers for the associated services. Start the services if start=yes.
Definition at line 204 of file ToolBarRegistrar.cpp.
References fwTools::fwID::exist(), m_editorSids, m_editorWids, OSLM_ASSERT, fwGui::GuiRegistry::registerSIDContainer(), and fwGui::GuiRegistry::registerWIDContainer().
Here is the call graph for this function: