X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/a660d684eda27638bca0384b2058911a31c8e845..704a4b7524e05d7bf4d208eb1b30be9989abef4c:/docs/latex/wx/evthand.tex diff --git a/docs/latex/wx/evthand.tex b/docs/latex/wx/evthand.tex index 16e10a1bcb..8f5c7a9567 100644 --- a/docs/latex/wx/evthand.tex +++ b/docs/latex/wx/evthand.tex @@ -8,6 +8,10 @@ this class. \helpref{wxObject}{wxobject} +\wxheading{Include files} + + + \wxheading{See also} \overview{Event handling overview}{eventhandlingoverview} @@ -28,6 +32,39 @@ Destructor. If the handler is part of a chain, the destructor will unlink itself and restore the previous and next handlers so that they point to each other. +\membersection{wxEvtHandler::Connect}\label{wxevthandlerconnect} + +\func{void}{Connect}{\param{int}{ id}, + \param{wxEventType }{eventType}, \param{wxObjectEventFunction}{ function}, + \param{wxObject*}{ userData = NULL}} + +\func{void}{Connect}{\param{int}{ id}, \param{int}{ lastId}, + \param{wxEventType }{eventType}, \param{wxObjectEventFunction}{ function}, + \param{wxObject*}{ userData = NULL}} + +Connects the given function dynamically with the event handler, id and event type. This +is an alternative to the use of static event tables. See the 'dynamic' sample for usage. + +\wxheading{Parameters} + +\docparam{id}{The identifier (or first of the identifier range) to be associated with the event handler function.} + +\docparam{lastId}{The second part of the identifier range to be associated with the event handler function.} + +\docparam{eventType}{The event type to be associated with this event handler.} + +\docparam{function}{The event handler function.} + +\docparam{userData}{Data to be associated with the event table entry.} + +\wxheading{Example} + +\begin{verbatim} + frame->Connect( wxID_EXIT, + wxEVT_COMMAND_MENU_SELECTED, + (wxObjectEventFunction) (wxEventFunction) (wxCommandEventFunction) MyFrame::OnQuit ); +\end{verbatim} + \membersection{wxEvtHandler::Default}\label{wxevthandlerdefault} \func{virtual long}{Default}{\void} @@ -204,8 +241,7 @@ Sets user-supplied client data. Normally, any extra data the programmer wishes to associate with the object should be made available by deriving a new class with new data members. - -TODO: make this void*, char* only in compatibility mode. +%TODO: make this void*, char* only in compatibility mode. \wxheading{See also}