]> git.saurik.com Git - wxWidgets.git/blame - samples/joytest/joytest.h
Missing header.
[wxWidgets.git] / samples / joytest / joytest.h
CommitLineData
bbf1f0e5
KB
1/////////////////////////////////////////////////////////////////////////////
2// Name: joytest.cpp
3// Purpose: Joystick sample
4// Author: Julian Smart
5// Modified by:
6// Created: 04/01/98
7// RCS-ID: $Id$
6aa89a22 8// Copyright: (c) Julian Smart
2f6c54eb 9// Licence: wxWindows license
bbf1f0e5
KB
10/////////////////////////////////////////////////////////////////////////////
11
12// Define a new application
13class MyApp: public wxApp
14{
aec18ff7
MB
15public:
16 bool OnInit();
bbf1f0e5
KB
17
18 // Joystick max values
a800dc50
RD
19 int m_minX;
20 int m_minY;
bbf1f0e5
KB
21 int m_maxX;
22 int m_maxY;
23
d93966b9
VS
24#if wxUSE_SOUND
25 wxSound m_fire;
26#endif // wxUSE_SOUND
bbf1f0e5
KB
27};
28
29DECLARE_APP(MyApp)
30
31class MyCanvas: public wxScrolledWindow
32{
aec18ff7 33public:
bbf1f0e5 34 MyCanvas(wxWindow *parent, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize);
aec18ff7 35 ~MyCanvas();
bbf1f0e5
KB
36 void OnJoystickEvent(wxJoystickEvent& event);
37
a800dc50 38 wxJoystick* m_stick;
bbf1f0e5
KB
39 DECLARE_EVENT_TABLE()
40};
41
42class MyFrame: public wxFrame
43{
aec18ff7 44public:
bbf1f0e5 45 MyCanvas *canvas;
aec18ff7
MB
46 MyFrame(wxFrame *parent, const wxString& title,
47 const wxPoint& pos, const wxSize& size, const long style);
925e9792 48 ~MyFrame(){};
bbf1f0e5
KB
49 void OnActivate(wxActivateEvent& event);
50 void OnQuit(wxCommandEvent& event);
51
52DECLARE_EVENT_TABLE()
53};
54
55#define JOYTEST_QUIT 1