correct the process of failure of resizing a window

This commit is contained in:
Jinhao
2017-09-28 08:29:19 +08:00
parent 8d9351e051
commit d715c87d93
8 changed files with 115 additions and 131 deletions

View File

@@ -291,6 +291,12 @@ namespace paint
return (impl_->handle ? impl_->handle->context : nullptr);
}
void graphics::swap(graphics& other)
{
if (context() != other.context())
impl_.swap(other.impl_);
}
void graphics::make(const ::nana::size& sz)
{
if (impl_->handle == nullptr || impl_->size != sz)