11 #include <fwGui/registry/macros.hpp> 13 #include "fwGuiQt/container/QtMenuContainer.hpp" 14 #include "fwGuiQt/layoutManager/MenuBarLayoutManager.hpp" 18 ::fwGui::layoutManager::IMenuBarLayoutManager::REGISTRY_KEY );
22 namespace layoutManager
33 MenuBarLayoutManager::~MenuBarLayoutManager()
43 m_parent = ::fwGuiQt::container::QtMenuBarContainer::dynamicCast(parent);
44 SLM_ASSERT(
"dynamicCast fwMenuBar to QtMenuBarContainer failed", m_parent);
46 QMenuBar* menuBar = m_parent->getQtMenuBar();
50 ::fwGuiQt::container::QtMenuContainer::sptr menu = ::fwGuiQt::container::QtMenuContainer::New();
51 QMenu *qtMenu = menuBar->addMenu(QString::fromStdString( name ));
52 menu->setQtMenu(qtMenu);
71 ::fwGuiQt::container::QtMenuContainer::sptr menuContainer = ::fwGuiQt::container::QtMenuContainer::dynamicCast(
73 QMenu *menu = menuContainer->getQtMenu();
74 menu->setVisible(isVisible);
81 ::fwGuiQt::container::QtMenuContainer::sptr menuContainer = ::fwGuiQt::container::QtMenuContainer::dynamicCast(
83 QMenu *menu = menuContainer->getQtMenu();
84 menu->setEnabled(isEnabled);
The namespace fwGui contains the base interface for IHM services.
#define SLM_TRACE_FUNC()
Trace contextual function signature.
Key class used to restrict access to Object construction. See http://www.drdobbs.com/184402053.
#define SLM_ASSERT(message, cond)
work like 'assert' from 'cassert', with in addition a message logged by spylog (with FATAL loglevel) ...