Fix different exception specifiers in image.cpp

This commit is contained in:
nabijaczleweli 2016-01-27 17:42:21 +01:00
parent 3c8ee33ae8
commit 8ea8322fc3
No known key found for this signature in database
GPG Key ID: BCFD0B018D2658F1

View File

@ -308,7 +308,7 @@ namespace paint
std::shared_ptr<image::image_impl_interface> ptr;
auto meta = *reinterpret_cast<const unsigned short*>(data);
if (*reinterpret_cast<const short*>("BM") == meta)
ptr = std::make_shared<detail::image_bmp>();
else if (*reinterpret_cast<const short*>("MZ") == meta)
@ -355,17 +355,17 @@ namespace paint
return (image_ptr_ ? &image::empty : nullptr);
}
void image::close()
void image::close() noexcept
{
image_ptr_.reset();
}
bool image::alpha() const
bool image::alpha() const noexcept
{
return (image_ptr_ ? image_ptr_->alpha_channel() : false);
}
nana::size image::size() const
nana::size image::size() const noexcept
{
return (image_ptr_ ? image_ptr_->size() : nana::size());
}