// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
-#if defined(__BORLANDC__)
+#ifdef __BORLANDC__
#pragma hdrstop
#endif
-#include <windows.h>
+#include "wx/string.h"
+#include "wx/window.h"
+#include "wx/msw/private.h"
#ifndef __GNUWIN32__
#include <mmsystem.h>
typedef UINT MMRESULT;
#endif
+#ifndef __TWIN32__
#ifdef __GNUWIN32__
#include <wx/msw/gnuwin32/extra.h>
#endif
+#endif
// Why doesn't BC++ have joyGetPosEx?
-#if !defined(__WIN32__) || defined(__BORLANDC__)
+#if !defined(__WIN32__) || defined(__BORLANDC__) || defined(__TWIN32__)
#define NO_JOYGETPOSEX
#endif
+#include <wx/window.h>
#include <wx/msw/joystick.h>
IMPLEMENT_DYNAMIC_CLASS(wxJoystick, wxObject)
int wxJoystick::GetNumberAxes(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return 0;
int wxJoystick::GetMaxButtons(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return 0;
int wxJoystick::GetMaxAxes(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return 0;
int wxJoystick::GetRudderMin(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return 0;
int wxJoystick::GetRudderMax(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return 0;
int wxJoystick::GetUMin(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return 0;
int wxJoystick::GetUMax(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return 0;
int wxJoystick::GetVMin(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return 0;
int wxJoystick::GetVMax(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return 0;
bool wxJoystick::HasRudder(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return FALSE;
bool wxJoystick::HasZ(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return FALSE;
bool wxJoystick::HasU(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return FALSE;
bool wxJoystick::HasV(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return FALSE;
bool wxJoystick::HasPOV(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return FALSE;
bool wxJoystick::HasPOV4Dir(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return FALSE;
bool wxJoystick::HasPOVCTS(void) const
{
-#ifdef __WIN32__
+#if defined(__WIN32__) && !defined(__TWIN32__)
JOYCAPS joyCaps;
if (joyGetDevCaps(m_joystick, & joyCaps, sizeof(JOYCAPS)) != JOYERR_NOERROR)
return FALSE;