I am not sure that this is needed, because with the limited samples there has never been a problem. It may well be that our use of qt will never have additional pending signals when a slot is called, but it's hard to tell.
Consider winevent.h:29
void EmitEvent( wxEvent &event ) const
{
wxWindow *handler = GetHandler();
event.SetEventObject( handler );
handler->HandleWindowEvent( event );
}
Instead
void EmitEvent( wxEvent *event ) const
{
wxWindow *handler = GetHandler();
event->SetEventObject( handler );
handler->GetEventHandler()->QueueEvent( event );
}
I am asking because this difference could have many implications. I'm not sure if it is better or not, but I think it avoids any cases where we would need to call deleteLater in the dtor.
Sean