diff --git a/source/gui/screen.cpp b/source/gui/screen.cpp index b16eb9d8..a5de12a8 100644 --- a/source/gui/screen.cpp +++ b/source/gui/screen.cpp @@ -130,7 +130,7 @@ namespace nana { //It is only when the screen is a moved-from object that impl_ is empty if (!impl_) - impl_.swap(std::make_shared()); + std::make_shared().swap(impl_); impl_->load_monitors(); }