]> git.saurik.com Git - wxWidgets.git/blame - include/wx/qt/joystick.h
Small fixes to defs.h; change "windows.h" to <windows.h> in filefn.cpp
[wxWidgets.git] / include / wx / qt / joystick.h
CommitLineData
7c78e7c7
RR
1/////////////////////////////////////////////////////////////////////////////
2// Name: joystick.h
3// Purpose: wxJoystick class
01b2eeec 4// Author: AUTHOR
7c78e7c7 5// Modified by:
01b2eeec 6// Created: ??/??/98
7c78e7c7 7// RCS-ID: $Id$
01b2eeec 8// Copyright: (c) AUTHOR
7c78e7c7
RR
9// Licence: wxWindows licence
10/////////////////////////////////////////////////////////////////////////////
11
01b2eeec
KB
12#ifndef _WX_JOYSTICK_H_
13#define _WX_JOYSTICK_H_
7c78e7c7
RR
14
15#ifdef __GNUG__
16#pragma interface "joystick.h"
17#endif
18
19#include "wx/event.h"
7c78e7c7 20
01b2eeec 21class WXDLLEXPORT wxJoystick: public wxObject
7c78e7c7
RR
22{
23 DECLARE_DYNAMIC_CLASS(wxJoystick)
24 public:
25 /*
26 * Public interface
27 */
28
01b2eeec 29 wxJoystick(int joystick = wxJOYSTICK1) { m_joystick = joystick; };
7c78e7c7
RR
30
31 // Attributes
32 ////////////////////////////////////////////////////////////////////////////
33
01b2eeec
KB
34 wxPoint GetPosition() const;
35 int GetZPosition() const;
36 int GetButtonState() const;
37 int GetPOVPosition() const;
38 int GetPOVCTSPosition() const;
39 int GetRudderPosition() const;
40 int GetUPosition() const;
41 int GetVPosition() const;
42 int GetMovementThreshold() const;
7c78e7c7
RR
43 void SetMovementThreshold(int threshold) ;
44
45 // Capabilities
46 ////////////////////////////////////////////////////////////////////////////
47
01b2eeec
KB
48 bool IsOk() const; // Checks that the joystick is functioning
49 int GetNumberJoysticks() const ;
50 int GetManufacturerId() const ;
51 int GetProductId() const ;
52 wxString GetProductName() const ;
53 int GetXMin() const;
54 int GetYMin() const;
55 int GetZMin() const;
56 int GetXMax() const;
57 int GetYMax() const;
58 int GetZMax() const;
59 int GetNumberButtons() const;
60 int GetNumberAxes() const;
61 int GetMaxButtons() const;
62 int GetMaxAxes() const;
63 int GetPollingMin() const;
64 int GetPollingMax() const;
65 int GetRudderMin() const;
66 int GetRudderMax() const;
67 int GetUMin() const;
68 int GetUMax() const;
69 int GetVMin() const;
70 int GetVMax() const;
71
72 bool HasRudder() const;
73 bool HasZ() const;
74 bool HasU() const;
75 bool HasV() const;
76 bool HasPOV() const;
77 bool HasPOV4Dir() const;
78 bool HasPOVCTS() const;
7c78e7c7
RR
79
80 // Operations
81 ////////////////////////////////////////////////////////////////////////////
82
83 // pollingFreq = 0 means that movement events are sent when above the threshold.
84 // If pollingFreq > 0, events are received every this many milliseconds.
85 bool SetCapture(wxWindow* win, int pollingFreq = 0);
01b2eeec 86 bool ReleaseCapture();
7c78e7c7
RR
87
88protected:
89 int m_joystick;
7c78e7c7
RR
90};
91
92#endif
01b2eeec 93 // _WX_JOYSTICK_H_