]> git.saurik.com Git - wxWidgets.git/blame - docs/latex/wx/treeevt.tex
don't call wxYield() from EnsureVisible(), this is too dangerous - and unnecessary...
[wxWidgets.git] / docs / latex / wx / treeevt.tex
CommitLineData
a660d684
KB
1\section{\class{wxTreeEvent}}\label{wxtreeevent}
2
3A tree event holds information about events associated with wxTreeCtrl objects.
4
5\wxheading{Derived from}
6
86f975a8 7\helpref{wxNotifyEvent}{wxnotifyevent}\\
a660d684
KB
8\helpref{wxCommandEvent}{wxcommandevent}\\
9\helpref{wxEvent}{wxevent}\\
10\helpref{wxObject}{wxobject}
11
954b8ae6
JS
12\wxheading{Include files}
13
14<wx/treectrl.h>
15
a660d684
KB
16\wxheading{Event table macros}
17
18To process input from a tree control, use these event handler macros to direct input to member
19functions that take a wxTreeEvent argument.
20
21\twocolwidtha{7cm}
22\begin{twocollist}\itemsep=0pt
23\twocolitem{{\bf EVT\_TREE\_BEGIN\_DRAG(id, func)}}{Begin dragging with the left mouse button.}
24\twocolitem{{\bf EVT\_TREE\_BEGIN\_RDRAG(id, func)}}{Begin dragging with the right mouse button.}
fd128b0c
RR
25\twocolitem{{\bf EVT\_TREE\_BEGIN\_LABEL\_EDIT(id, func)}}{Begin editing a label. This can be prevented by calling \helpref{Veto()}{wxnotifyeventveto}.}
26\twocolitem{{\bf EVT\_TREE\_END\_LABEL\_EDIT(id, func)}}{Finish editing a label. This can be prevented by calling \helpref{Veto()}{wxnotifyeventveto}.}
a660d684
KB
27\twocolitem{{\bf EVT\_TREE\_DELETE\_ITEM(id, func)}}{Delete an item.}
28\twocolitem{{\bf EVT\_TREE\_GET\_INFO(id, func)}}{Request information from the application.}
29\twocolitem{{\bf EVT\_TREE\_SET\_INFO(id, func)}}{Information is being supplied.}
fb96bc75
VZ
30\twocolitem{{\bf EVT\_TREE\_ITEM\_COLLAPSED(id, func)}}{The item has been collapsed.}
31\twocolitem{{\bf EVT\_TREE\_ITEM\_COLLAPSING(id, func)}}{The item is being collapsed. This can be prevented by calling \helpref{Veto()}{wxnotifyeventveto}.}
32\twocolitem{{\bf EVT\_TREE\_ITEM\_EXPANDED(id, func)}}{The item has been expanded.}
33\twocolitem{{\bf EVT\_TREE\_ITEM\_EXPANDING(id, func)}}{The item is being expanded. This can be prevented by calling \helpref{Veto()}{wxnotifyeventveto}.}
a660d684 34\twocolitem{{\bf EVT\_TREE\_SEL\_CHANGED(id, func)}}{Selection has changed.}
fd128b0c 35\twocolitem{{\bf EVT\_TREE\_SEL\_CHANGING(id, func)}}{Selection is changing. This can be prevented by calling \helpref{Veto()}{wxnotifyeventveto}.}
a660d684
KB
36\twocolitem{{\bf EVT\_TREE\_KEY\_DOWN(id, func)}}{A key has been pressed.}
37\end{twocollist}%
38
39\wxheading{See also}
40
41\helpref{wxTreeCtrl}{wxtreectrl}
42
43\latexignore{\rtfignore{\wxheading{Members}}}
44
45\membersection{wxTreeEvent::wxTreeEvent}
46
47\func{}{wxTreeEvent}{\param{WXTYPE }{commandType = 0}, \param{int }{id = 0}}
48
49Constructor.
50
515da557 51\membersection{wxTreeEvent::GetItem}
a660d684 52
515da557 53\constfunc{wxTreeItemId}{GetItem}{}
a660d684 54
515da557 55Returns he item (valid for all events).
a660d684 56
515da557 57\membersection{wxTreeEvent::GetOldItem}
a660d684 58
515da557 59\constfunc{wxTreeItemId}{GetOldItem}{}
a660d684 60
515da557 61Returns the old item index (valid for EVT\_TREE\_ITEM\_CHANGING and CHANGED events)
a660d684 62
515da557 63\membersection{wxTreeEvent::GetPoint()}
a660d684 64
515da557 65\constfunc{wxPoint}{GetPoint}{}
a660d684 66
515da557 67Returns the position of the mouse pointer if the event is a drag event.
a660d684 68
515da557 69\membersection{wxTreeEvent::GetCode}
a660d684 70
515da557 71\constfunc{int}{GetCode}{}
a660d684 72
515da557 73The key code if the event was is a key event.
a660d684 74
515da557
RR
75\membersection{wxTreeEvent::GetLabel}
76
605d715d 77\constfunc{const wxString\&}{GetLabel}{}
515da557
RR
78
79Returns the label if the event was a begin or end edit label event.
7e9a386e 80