Remove wxAnimation copy ctor and copy-assignment operator implementations

The compiler-generated defaults will do the same thing
This commit is contained in:
Paul Cornett 2020-04-06 20:26:49 -07:00
parent 706c8e8ad6
commit 902a2f0885
2 changed files with 4 additions and 17 deletions

View File

@ -37,9 +37,11 @@ class WXDLLIMPEXP_CORE wxAnimation : public wxObject
public: public:
wxAnimation(); wxAnimation();
explicit wxAnimation(const wxString &name, wxAnimationType type = wxANIMATION_TYPE_ANY); explicit wxAnimation(const wxString &name, wxAnimationType type = wxANIMATION_TYPE_ANY);
wxAnimation(const wxAnimation& other);
wxAnimation& operator=(const wxAnimation& other); #if __cplusplus >= 201103
wxAnimation(const wxAnimation&) = default;
wxAnimation& operator=(const wxAnimation&) = default;
#endif
bool IsOk() const; bool IsOk() const;
bool IsCompatibleWith(wxClassInfo* ci) const; bool IsCompatibleWith(wxClassInfo* ci) const;

View File

@ -74,21 +74,6 @@ wxAnimation::wxAnimation(const wxString &name, wxAnimationType type)
LoadFile(name, type); LoadFile(name, type);
} }
wxAnimation::wxAnimation(const wxAnimation& other)
{
Ref(other);
}
wxAnimation& wxAnimation::operator=(const wxAnimation& other)
{
if (this != &other)
{
UnRef();
Ref(other);
}
return *this;
}
wxAnimationImpl* wxAnimation::GetImpl() const wxAnimationImpl* wxAnimation::GetImpl() const
{ {
return static_cast<wxAnimationImpl*>(m_refData); return static_cast<wxAnimationImpl*>(m_refData);