git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39765
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
// if the event object == this because the book control can have other
// subcontrols inside it (e.g. wxSpinButton in case of a notebook in wxUniv)
wxWindow *source = wxStaticCast(event.GetEventObject(), wxWindow);
// if the event object == this because the book control can have other
// subcontrols inside it (e.g. wxSpinButton in case of a notebook in wxUniv)
wxWindow *source = wxStaticCast(event.GetEventObject(), wxWindow);
- while ( source && source->GetParent() != this )
+ while ( source && source != this && source->GetParent() != this )
{
source = source->GetParent();
}
{
source = source->GetParent();
}