#include <comevt.h>

Public Member Functions | |
| a2dEventDistributer () | |
| constructor | |
| ~a2dEventDistributer () | |
| destructor | |
| bool | ProcessEvent (wxEvent &event) |
| process an event for the object, starting with the first eventhandler in the list. | |
| a2dDistributedEventReceiver * | Register (wxEvtHandler *handler) |
| register a class instance | |
| bool | Unregister (wxEvtHandler *handler) |
| UnRegister a class instance. | |
| a2dDistributedEventReceiver * | Register (a2dObject *handler) |
| register a class instance | |
| bool | Unregister (a2dObject *handler) |
| UnRegister a class instance. | |
Protected Attributes | |
| wxEventHandlersList | m_handlers |
| list of registrated class instances. | |
The events sent to this class or either directly sent to other classes that are registrated or in idle time. Registrated classes should be derived from wxEvtHandler.
The sending class calls
ProcessEvent( wxEvent& event) or AddPendingEvent( changed ).
The receiving class can use the standard way of receiving events in wxWindows.
BEGIN_EVENT_TABLE(wxMyClass, wxMyClassBase)
EVT_COM_EVENT( wxMyClass::OnComEvent )
END_EVENT_TABLE()
In the docview classes, the a2dEventDistributer is used to sent events from documents to views and the wxCommandProcessorEvents class.
Definition at line 1666 of file comevt.h.
| bool a2dEventDistributer::ProcessEvent | ( | wxEvent & | event | ) |
process an event for the object, starting with the first eventhandler in the list.
Only wxEvtHandler instances that are registred and valid are getting the event. It is allowed to unregister any wxEvtHandler while the event distribution is in progress. This unregistered wxEvtHandler, will be flagged invalid, and therefore no event will be sent to it anymore. At the end of the event distribution the unregistered wxEvtHandler's are removed.
Definition at line 1299 of file comevt.cpp.