You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
#include "widget.h"
|
|
|
|
Widget::Widget(const std::shared_ptr<Widget>& parent) :
|
|
_parent(parent)
|
|
{
|
|
if (_parent)
|
|
_parent->addChild(shared_from_this());
|
|
}
|
|
|
|
void Widget::addChild(const std::shared_ptr<Widget> &child)
|
|
{
|
|
_children.emplace_back(child);
|
|
}
|