1998-06-14 16:48:39 -04:00
|
|
|
\section{\class{wxJoystickEvent}}\label{wxjoystickevent}
|
|
|
|
|
|
|
|
This event class contains information about mouse events, particularly
|
|
|
|
events received by windows.
|
|
|
|
|
|
|
|
\wxheading{Derived from}
|
|
|
|
|
|
|
|
\helpref{wxEvent}{wxevent}
|
|
|
|
|
1999-02-15 15:41:29 -05:00
|
|
|
\wxheading{Include files}
|
|
|
|
|
|
|
|
<wx/event.h>
|
|
|
|
|
1998-06-14 16:48:39 -04:00
|
|
|
\wxheading{Event table macros}
|
|
|
|
|
|
|
|
To process a mouse event, use these event handler macros to direct input to member
|
|
|
|
functions that take a wxJoystickEvent argument.
|
|
|
|
|
|
|
|
\twocolwidtha{7cm}
|
|
|
|
\begin{twocollist}\itemsep=0pt
|
|
|
|
\twocolitem{{\bf EVT\_JOY\_BUTTON\_DOWN(func)}}{Process a wxEVT\_JOY\_BUTTON\_DOWN event.}
|
|
|
|
\twocolitem{{\bf EVT\_JOY\_BUTTON\_UP(func)}}{Process a wxEVT\_JOY\_BUTTON\_UP event.}
|
|
|
|
\twocolitem{{\bf EVT\_JOY\_MOVE(func)}}{Process a wxEVT\_JOY\_MOVE event.}
|
|
|
|
\twocolitem{{\bf EVT\_JOY\_ZMOVE(func)}}{Process a wxEVT\_JOY\_ZMOVE event.}
|
|
|
|
\end{twocollist}%
|
|
|
|
|
|
|
|
\wxheading{See also}
|
|
|
|
|
|
|
|
\helpref{wxJoystick}{wxjoystick}
|
|
|
|
|
|
|
|
\latexignore{\rtfignore{\wxheading{Members}}}
|
|
|
|
|
2004-09-29 07:25:34 -04:00
|
|
|
\membersection{wxJoystickEvent::wxJoystickEvent}\label{wxjoystickeventctor}
|
1998-06-14 16:48:39 -04:00
|
|
|
|
|
|
|
\func{}{wxJoystickEvent}{\param{WXTYPE}{ eventType = 0}, \param{int}{ state = 0},
|
|
|
|
\param{int}{ joystick = wxJOYSTICK1}, \param{int }{change = 0}}
|
|
|
|
|
|
|
|
Constructor.
|
|
|
|
|
|
|
|
\membersection{wxJoystickEvent::ButtonDown}\label{wxjoystickeventbuttondown}
|
|
|
|
|
|
|
|
\constfunc{bool}{ButtonDown}{\param{int}{ button = wxJOY\_BUTTON\_ANY}}
|
|
|
|
|
2003-01-17 19:16:34 -05:00
|
|
|
Returns true if the event was a down event from the specified button (or any button).
|
1998-06-14 16:48:39 -04:00
|
|
|
|
|
|
|
\wxheading{Parameters}
|
|
|
|
|
|
|
|
\docparam{button}{Can be wxJOY\_BUTTONn where n is 1, 2, 3 or 4; or wxJOY\_BUTTON\_ANY to
|
|
|
|
indicate any button down event.}
|
|
|
|
|
|
|
|
\membersection{wxJoystickEvent::ButtonIsDown}\label{wxjoystickeventbuttonisdown}
|
|
|
|
|
|
|
|
\constfunc{bool}{ButtonIsDown}{\param{int}{ button = wxJOY\_BUTTON\_ANY}}
|
|
|
|
|
2003-01-17 19:16:34 -05:00
|
|
|
Returns true if the specified button (or any button) was in a down state.
|
1998-06-14 16:48:39 -04:00
|
|
|
|
|
|
|
\wxheading{Parameters}
|
|
|
|
|
|
|
|
\docparam{button}{Can be wxJOY\_BUTTONn where n is 1, 2, 3 or 4; or wxJOY\_BUTTON\_ANY to
|
|
|
|
indicate any button down event.}
|
|
|
|
|
|
|
|
\membersection{wxJoystickEvent::ButtonUp}\label{wxjoystickeventbuttonup}
|
|
|
|
|
|
|
|
\constfunc{bool}{ButtonUp}{\param{int}{ button = wxJOY\_BUTTON\_ANY}}
|
|
|
|
|
2003-01-17 19:16:34 -05:00
|
|
|
Returns true if the event was an up event from the specified button (or any button).
|
1998-06-14 16:48:39 -04:00
|
|
|
|
|
|
|
\wxheading{Parameters}
|
|
|
|
|
|
|
|
\docparam{button}{Can be wxJOY\_BUTTONn where n is 1, 2, 3 or 4; or wxJOY\_BUTTON\_ANY to
|
|
|
|
indicate any button down event.}
|
|
|
|
|
|
|
|
\membersection{wxJoystickEvent::GetButtonChange}\label{wxjoystickeventgetbuttonchange}
|
|
|
|
|
|
|
|
\constfunc{int}{GetButtonChange}{\void}
|
|
|
|
|
|
|
|
Returns the identifier of the button changing state. This is a wxJOY\_BUTTONn identifier, where
|
|
|
|
n is one of 1, 2, 3, 4.
|
|
|
|
|
|
|
|
\membersection{wxJoystickEvent::GetButtonState}\label{wxjoystickeventgetbuttonstate}
|
|
|
|
|
|
|
|
\constfunc{int}{GetButtonState}{\void}
|
|
|
|
|
|
|
|
Returns the down state of the buttons. This is a bitlist of wxJOY\_BUTTONn identifiers, where
|
|
|
|
n is one of 1, 2, 3, 4.
|
|
|
|
|
|
|
|
\membersection{wxJoystickEvent::GetJoystick}\label{wxjoystickeventgetjoystick}
|
|
|
|
|
|
|
|
\constfunc{int}{GetJoystick}{\void}
|
|
|
|
|
|
|
|
Returns the identifier of the joystick generating the event - one of wxJOYSTICK1 and wxJOYSTICK2.
|
|
|
|
|
|
|
|
\membersection{wxJoystickEvent::GetPosition}\label{wxjoystickeventgetposition}
|
|
|
|
|
|
|
|
\constfunc{wxPoint}{GetPosition}{\void}
|
|
|
|
|
|
|
|
Returns the x, y position of the joystick event.
|
|
|
|
|
|
|
|
\membersection{wxJoystickEvent::GetZPosition}\label{wxjoystickeventgetzposition}
|
|
|
|
|
|
|
|
\constfunc{int}{GetZPosition}{\void}
|
|
|
|
|
|
|
|
Returns the z position of the joystick event.
|
|
|
|
|
|
|
|
\membersection{wxJoystickEvent::IsButton}\label{wxjoystickeventisbutton}
|
|
|
|
|
|
|
|
\constfunc{bool}{IsButton}{\void}
|
|
|
|
|
2003-01-17 19:16:34 -05:00
|
|
|
Returns true if this was a button up or down event ({\it not} 'is any button down?').
|
1998-06-14 16:48:39 -04:00
|
|
|
|
|
|
|
\membersection{wxJoystickEvent::IsMove}\label{wxjoystickeventismove}
|
|
|
|
|
|
|
|
\constfunc{bool}{IsMove}{\void}
|
|
|
|
|
2003-01-17 19:16:34 -05:00
|
|
|
Returns true if this was an x, y move event.
|
1998-06-14 16:48:39 -04:00
|
|
|
|
|
|
|
\membersection{wxJoystickEvent::IsZMove}\label{wxjoystickeventiszmove}
|
|
|
|
|
|
|
|
\constfunc{bool}{IsZMove}{\void}
|
|
|
|
|
2003-01-17 19:16:34 -05:00
|
|
|
Returns true if this was a z move event.
|
1998-06-14 16:48:39 -04:00
|
|
|
|