Fix wxRTTI for wxAnimationCtrl when using generic implementation
It must use wxGenericAnimationCtrl as the base class in wxRTTI, as otherwise wxAnimation::IsCompatibleWith() would fail in this case for the generic implementation of wxAnimation.
This commit is contained in:
@@ -43,7 +43,10 @@ wxIMPLEMENT_DYNAMIC_CLASS(wxAnimation, wxObject);
|
||||
|
||||
#if !defined(wxHAS_NATIVE_ANIMATIONCTRL)
|
||||
// In this case the "native" ctrl is the generic ctrl. See wx/animate.h
|
||||
wxIMPLEMENT_CLASS(wxAnimationCtrl, wxControl);
|
||||
// Notice that it's important to use wxGenericAnimationCtrl here because
|
||||
// wxAnimation::IsCompatibleWith() relies on control deriving from
|
||||
// wxGenericAnimationCtrl when using generic wxAnimation implementation.
|
||||
wxIMPLEMENT_CLASS(wxAnimationCtrl, wxGenericAnimationCtrl);
|
||||
#endif
|
||||
|
||||
#include "wx/listimpl.cpp"
|
||||
|
Reference in New Issue
Block a user