Change in wxWindow the access specifier of the wxEvtHandler event processing and queuing functions
from public to protected. Adapt wxWidgets code and wxWidgets samples to always use wxWindow::GetEventHandler() when calling such functions on a wxWindow rather than directly using wxWindow::ProcessEvent, etc. This enables correct event dispatching to the event handlers which have been pushed (with PushEventHandler) on the windows. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@58381 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -3086,6 +3086,25 @@ protected:
|
||||
explanations of when you might want to do it.
|
||||
*/
|
||||
void SendDestroyEvent();
|
||||
|
||||
//@{
|
||||
/**
|
||||
This function is public in wxEvtHandler but is protected in wxWindow because
|
||||
for wxWindows you should always use this function on the pointer returned
|
||||
by GetEventHandler() and not on the wxWindow object itself.
|
||||
|
||||
Note that it's still possible to call these functions directly on the
|
||||
wxWindow object (e.g. downcasting it to wxEvtHandler) but doing that
|
||||
will create subtle bugs when windows with event handlers pushed on them
|
||||
are involved.
|
||||
*/
|
||||
virtual bool ProcessEvent(wxEvent& event);
|
||||
bool SafelyProcessEvent(wxEvent& event);
|
||||
virtual void QueueEvent(wxEvent *event);
|
||||
virtual void AddPendingEvent(const wxEvent& event);
|
||||
void ProcessPendingEvents();
|
||||
bool ProcessThreadEvent(const wxEvent& event);
|
||||
//@}
|
||||
};
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user