#include namespace psemek::ui { std::shared_ptr frame::set_child(std::shared_ptr c) { auto old = std::move(child_); if (old) old->set_parent(nullptr); child_ = std::move(c); if (child_) child_->set_parent(this); children_[0] = child_.get(); return old; } void frame::set_min_size(std::optional> const & size) { min_size_ = size; post_reshape(); } void frame::set_max_size(std::optional> const & size) { max_size_ = size; post_reshape(); } void frame::set_fixed_size(geom::vector const & size) { min_size_ = size; max_size_ = size; post_reshape(); } }