]> git.saurik.com Git - wxWidgets.git/blame - docs/latex/wx/joyevent.tex
Documented new menu label functions
[wxWidgets.git] / docs / latex / wx / joyevent.tex
CommitLineData
fe604ccd
JS
1\section{\class{wxJoystickEvent}}\label{wxjoystickevent}
2
3This event class contains information about mouse events, particularly
4events received by windows.
5
6\wxheading{Derived from}
7
8\helpref{wxEvent}{wxevent}
9
954b8ae6
JS
10\wxheading{Include files}
11
12<wx/event.h>
13
a7af285d
VZ
14\wxheading{Library}
15
16\helpref{wxCore}{librarieslist}
17
fe604ccd
JS
18\wxheading{Event table macros}
19
20To process a mouse event, use these event handler macros to direct input to member
21functions that take a wxJoystickEvent argument.
22
23\twocolwidtha{7cm}
24\begin{twocollist}\itemsep=0pt
25\twocolitem{{\bf EVT\_JOY\_BUTTON\_DOWN(func)}}{Process a wxEVT\_JOY\_BUTTON\_DOWN event.}
26\twocolitem{{\bf EVT\_JOY\_BUTTON\_UP(func)}}{Process a wxEVT\_JOY\_BUTTON\_UP event.}
27\twocolitem{{\bf EVT\_JOY\_MOVE(func)}}{Process a wxEVT\_JOY\_MOVE event.}
28\twocolitem{{\bf EVT\_JOY\_ZMOVE(func)}}{Process a wxEVT\_JOY\_ZMOVE event.}
6fdd4565 29\twocolitem{{\bf EVT\_JOYSTICK\_EVENTS(func)}}{Processes all joystick events.}
fe604ccd
JS
30\end{twocollist}%
31
32\wxheading{See also}
33
34\helpref{wxJoystick}{wxjoystick}
35
36\latexignore{\rtfignore{\wxheading{Members}}}
37
f0e8a2d0 38\membersection{wxJoystickEvent::wxJoystickEvent}\label{wxjoystickeventctor}
fe604ccd
JS
39
40\func{}{wxJoystickEvent}{\param{WXTYPE}{ eventType = 0}, \param{int}{ state = 0},
41 \param{int}{ joystick = wxJOYSTICK1}, \param{int }{change = 0}}
42
43Constructor.
44
45\membersection{wxJoystickEvent::ButtonDown}\label{wxjoystickeventbuttondown}
46
47\constfunc{bool}{ButtonDown}{\param{int}{ button = wxJOY\_BUTTON\_ANY}}
48
cc81d32f 49Returns true if the event was a down event from the specified button (or any button).
fe604ccd
JS
50
51\wxheading{Parameters}
52
53\docparam{button}{Can be wxJOY\_BUTTONn where n is 1, 2, 3 or 4; or wxJOY\_BUTTON\_ANY to
54indicate any button down event.}
55
56\membersection{wxJoystickEvent::ButtonIsDown}\label{wxjoystickeventbuttonisdown}
57
58\constfunc{bool}{ButtonIsDown}{\param{int}{ button = wxJOY\_BUTTON\_ANY}}
59
cc81d32f 60Returns true if the specified button (or any button) was in a down state.
fe604ccd
JS
61
62\wxheading{Parameters}
63
64\docparam{button}{Can be wxJOY\_BUTTONn where n is 1, 2, 3 or 4; or wxJOY\_BUTTON\_ANY to
65indicate any button down event.}
66
67\membersection{wxJoystickEvent::ButtonUp}\label{wxjoystickeventbuttonup}
68
69\constfunc{bool}{ButtonUp}{\param{int}{ button = wxJOY\_BUTTON\_ANY}}
70
cc81d32f 71Returns true if the event was an up event from the specified button (or any button).
fe604ccd
JS
72
73\wxheading{Parameters}
74
75\docparam{button}{Can be wxJOY\_BUTTONn where n is 1, 2, 3 or 4; or wxJOY\_BUTTON\_ANY to
76indicate any button down event.}
77
78\membersection{wxJoystickEvent::GetButtonChange}\label{wxjoystickeventgetbuttonchange}
79
80\constfunc{int}{GetButtonChange}{\void}
81
82Returns the identifier of the button changing state. This is a wxJOY\_BUTTONn identifier, where
83n is one of 1, 2, 3, 4.
84
85\membersection{wxJoystickEvent::GetButtonState}\label{wxjoystickeventgetbuttonstate}
86
87\constfunc{int}{GetButtonState}{\void}
88
89Returns the down state of the buttons. This is a bitlist of wxJOY\_BUTTONn identifiers, where
90n is one of 1, 2, 3, 4.
91
92\membersection{wxJoystickEvent::GetJoystick}\label{wxjoystickeventgetjoystick}
93
94\constfunc{int}{GetJoystick}{\void}
95
96Returns the identifier of the joystick generating the event - one of wxJOYSTICK1 and wxJOYSTICK2.
97
98\membersection{wxJoystickEvent::GetPosition}\label{wxjoystickeventgetposition}
99
100\constfunc{wxPoint}{GetPosition}{\void}
101
102Returns the x, y position of the joystick event.
103
104\membersection{wxJoystickEvent::GetZPosition}\label{wxjoystickeventgetzposition}
105
106\constfunc{int}{GetZPosition}{\void}
107
108Returns the z position of the joystick event.
109
110\membersection{wxJoystickEvent::IsButton}\label{wxjoystickeventisbutton}
111
112\constfunc{bool}{IsButton}{\void}
113
cc81d32f 114Returns true if this was a button up or down event ({\it not} 'is any button down?').
fe604ccd
JS
115
116\membersection{wxJoystickEvent::IsMove}\label{wxjoystickeventismove}
117
118\constfunc{bool}{IsMove}{\void}
119
cc81d32f 120Returns true if this was an x, y move event.
fe604ccd
JS
121
122\membersection{wxJoystickEvent::IsZMove}\label{wxjoystickeventiszmove}
123
124\constfunc{bool}{IsZMove}{\void}
125
cc81d32f 126Returns true if this was a z move event.
fe604ccd 127