using C++17 emplace return type

This commit is contained in:
Jinhao
2018-08-27 06:51:20 +08:00
parent fe185e382b
commit 81d667dbd7
12 changed files with 78 additions and 13 deletions

View File

@@ -742,8 +742,14 @@ namespace nana
void _m_add_agent(const detail::place_agent& ag) override
{
#ifdef _nana_std_has_emplace_return_type
this->operator<<(
widgets_.emplace_back(ag.create(place_ptr_->window_handle()))->handle()
);
#else
widgets_.emplace_back(ag.create(place_ptr_->window_handle()));
this->operator<<(widgets_.back()->handle());
#endif
}
public:
division* attached{ nullptr };