7 #include "fwGuiQt/builder/SlideViewBuilder.hpp" 9 #include "fwGuiQt/container/QtContainer.hpp" 10 #include <fwGuiQt/widget/SlideBar.hpp> 12 #include <fwGui/registry/macros.hpp> 31 SlideViewBuilder::~SlideViewBuilder()
39 m_parent = ::fwGuiQt::container::QtContainer::dynamicCast(parent);
40 SLM_ASSERT(
"The parent container is not a QtContainer", m_parent);
42 QWidget* qtParent = m_parent->getQtContainer();
44 ::fwGuiQt::widget::SlideBar::Aligment align = ::fwGuiQt::widget::SlideBar::LEFT;
47 case ISlideViewBuilder::LEFT:
48 align = ::fwGuiQt::widget::SlideBar::LEFT;
50 case ISlideViewBuilder::RIGHT:
51 align = ::fwGuiQt::widget::SlideBar::RIGHT;
53 case ISlideViewBuilder::TOP:
54 align = ::fwGuiQt::widget::SlideBar::TOP;
56 case ISlideViewBuilder::BOTTOM:
57 align = ::fwGuiQt::widget::SlideBar::BOTTOM;
65 if (!m_styleSheet.empty())
67 slideBar->setStyleSheet(QString::fromStdString(m_styleSheet));
70 ::fwGuiQt::container::QtContainer::sptr qtContainer = ::fwGuiQt::container::QtContainer::New();
71 qtContainer->setQtContainer(slideBar);
73 m_container = qtContainer;
80 SLM_ASSERT(
"The Container is not initialized", m_container);
82 m_container->destroyContainer();
The namespace fwGui contains the base interface for IHM services.
Key class used to restrict access to Object construction. See http://www.drdobbs.com/184402053.
Defines the qt implementation of the slide view builder.
#define SLM_ASSERT(message, cond)
work like 'assert' from 'cassert', with in addition a message logged by spylog (with FATAL loglevel) ...
virtual FWGUIQT_API void destroyContainer() override
Destroy local layout with sub containers.
virtual FWGUIQT_API void createContainer(::fwGui::container::fwContainer::sptr parent) override
Create the slide view container.