32 #ifndef CXREPLACABLECONTENTWIDGET_H 33 #define CXREPLACABLECONTENTWIDGET_H 36 #include <QVBoxLayout> 37 #include <boost/shared_ptr.hpp> 52 mLayout =
new QVBoxLayout(
this);
53 mLayout->setMargin(0);
57 this->
setWidget(boost::shared_ptr<QWidget>());
62 this->setWidgetDontDeleteOld(widget.get());
63 mWidgetBoostPointer = widget;
67 QWidget* oldwidget = mWidget;
68 this->setWidgetDontDeleteOld(widget);
80 boost::shared_ptr<QWidget> mWidgetBoostPointer;
82 void setWidgetDontDeleteOld(QWidget* widget)
88 mWidget->setParent(NULL);
93 mLayout->addWidget(mWidget);
101 #endif // CXREPLACABLECONTENTWIDGET_H ReplacableContentWidget(QWidget *parent)
void setWidget(boost::shared_ptr< QWidget > widget)
void setWidgetDeleteOld(QWidget *widget)
~ReplacableContentWidget()
Namespace for all CustusX production code.