attempted vs2008 compile fix

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@3102 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
TimeServ 2009-01-18 01:47:48 +00:00
parent e3017a8fe4
commit 8b658df029
6 changed files with 2851 additions and 2803 deletions

View File

@ -73,7 +73,7 @@ typedef struct tagRAWMOUSE {
USHORT usButtonFlags; USHORT usButtonFlags;
USHORT usButtonData; USHORT usButtonData;
}; };
} buttondata; };
ULONG ulRawButtons; ULONG ulRawButtons;
LONG lLastX; LONG lLastX;
LONG lLastY; LONG lLastY;

View File

@ -1803,36 +1803,36 @@ void IN_RawInput_MouseRead(HANDLE in_device_handle)
} }
// buttons // buttons
if (raw->data.mouse.buttondata.usButtonFlags & RI_MOUSE_BUTTON_1_DOWN) if (raw->data.mouse.usButtonFlags & RI_MOUSE_BUTTON_1_DOWN)
Key_Event(K_MOUSE1, true); Key_Event(K_MOUSE1, true);
if (raw->data.mouse.buttondata.usButtonFlags & RI_MOUSE_BUTTON_1_UP) if (raw->data.mouse.usButtonFlags & RI_MOUSE_BUTTON_1_UP)
Key_Event(K_MOUSE1, false); Key_Event(K_MOUSE1, false);
if (raw->data.mouse.buttondata.usButtonFlags & RI_MOUSE_BUTTON_2_DOWN) if (raw->data.mouse.usButtonFlags & RI_MOUSE_BUTTON_2_DOWN)
Key_Event(K_MOUSE2, true); Key_Event(K_MOUSE2, true);
if (raw->data.mouse.buttondata.usButtonFlags & RI_MOUSE_BUTTON_2_UP) if (raw->data.mouse.usButtonFlags & RI_MOUSE_BUTTON_2_UP)
Key_Event(K_MOUSE2, false); Key_Event(K_MOUSE2, false);
if (raw->data.mouse.buttondata.usButtonFlags & RI_MOUSE_BUTTON_3_DOWN) if (raw->data.mouse.usButtonFlags & RI_MOUSE_BUTTON_3_DOWN)
Key_Event(K_MOUSE3, true); Key_Event(K_MOUSE3, true);
if (raw->data.mouse.buttondata.usButtonFlags & RI_MOUSE_BUTTON_3_UP) if (raw->data.mouse.usButtonFlags & RI_MOUSE_BUTTON_3_UP)
Key_Event(K_MOUSE3, false); Key_Event(K_MOUSE3, false);
if (raw->data.mouse.buttondata.usButtonFlags & RI_MOUSE_BUTTON_4_DOWN) if (raw->data.mouse.usButtonFlags & RI_MOUSE_BUTTON_4_DOWN)
Key_Event(K_MOUSE4, true); Key_Event(K_MOUSE4, true);
if (raw->data.mouse.buttondata.usButtonFlags & RI_MOUSE_BUTTON_4_UP) if (raw->data.mouse.usButtonFlags & RI_MOUSE_BUTTON_4_UP)
Key_Event(K_MOUSE4, false); Key_Event(K_MOUSE4, false);
if (raw->data.mouse.buttondata.usButtonFlags & RI_MOUSE_BUTTON_5_DOWN) if (raw->data.mouse.usButtonFlags & RI_MOUSE_BUTTON_5_DOWN)
Key_Event(K_MOUSE5, true); Key_Event(K_MOUSE5, true);
if (raw->data.mouse.buttondata.usButtonFlags & RI_MOUSE_BUTTON_5_UP) if (raw->data.mouse.usButtonFlags & RI_MOUSE_BUTTON_5_UP)
Key_Event(K_MOUSE5, false); Key_Event(K_MOUSE5, false);
// mouse wheel // mouse wheel
if (raw->data.mouse.buttondata.usButtonFlags & RI_MOUSE_WHEEL) if (raw->data.mouse.usButtonFlags & RI_MOUSE_WHEEL)
{ // If the current message has a mouse_wheel message { // If the current message has a mouse_wheel message
if ((SHORT)raw->data.mouse.buttondata.usButtonData > 0) if ((SHORT)raw->data.mouse.usButtonData > 0)
{ {
Key_Event(K_MWHEELUP, true); Key_Event(K_MWHEELUP, true);
Key_Event(K_MWHEELUP, false); Key_Event(K_MWHEELUP, false);
} }
if ((SHORT)raw->data.mouse.buttondata.usButtonData < 0) if ((SHORT)raw->data.mouse.usButtonData < 0)
{ {
Key_Event(K_MWHEELDOWN, true); Key_Event(K_MWHEELDOWN, true);
Key_Event(K_MWHEELDOWN, false); Key_Event(K_MWHEELDOWN, false);

View File

@ -15,12 +15,24 @@
#endif #endif
#ifndef MK_XBUTTON1 #ifndef MK_XBUTTON1
#define MK_XBUTTON1 0x0020 #define MK_XBUTTON1 0x0020
#endif
#ifndef MK_XBUTTON2
#define MK_XBUTTON2 0x0040 #define MK_XBUTTON2 0x0040
#endif
// copied from DarkPlaces in an attempt to grab more buttons // copied from DarkPlaces in an attempt to grab more buttons
#ifndef MK_XBUTTON3
#define MK_XBUTTON3 0x0080 #define MK_XBUTTON3 0x0080
#endif
#ifndef MK_XBUTTON4
#define MK_XBUTTON4 0x0100 #define MK_XBUTTON4 0x0100
#endif
#ifndef MK_XBUTTON5
#define MK_XBUTTON5 0x0200 #define MK_XBUTTON5 0x0200
#endif
#ifndef MK_XBUTTON6
#define MK_XBUTTON6 0x0400 #define MK_XBUTTON6 0x0400
#endif
#ifndef MK_XBUTTON7
#define MK_XBUTTON7 0x0800 #define MK_XBUTTON7 0x0800
#endif #endif

View File

@ -15,12 +15,24 @@
#endif #endif
#ifndef MK_XBUTTON1 #ifndef MK_XBUTTON1
#define MK_XBUTTON1 0x0020 #define MK_XBUTTON1 0x0020
#endif
#ifndef MK_XBUTTON2
#define MK_XBUTTON2 0x0040 #define MK_XBUTTON2 0x0040
#endif
// copied from DarkPlaces in an attempt to grab more buttons // copied from DarkPlaces in an attempt to grab more buttons
#ifndef MK_XBUTTON3
#define MK_XBUTTON3 0x0080 #define MK_XBUTTON3 0x0080
#endif
#ifndef MK_XBUTTON4
#define MK_XBUTTON4 0x0100 #define MK_XBUTTON4 0x0100
#endif
#ifndef MK_XBUTTON5
#define MK_XBUTTON5 0x0200 #define MK_XBUTTON5 0x0200
#endif
#ifndef MK_XBUTTON6
#define MK_XBUTTON6 0x0400 #define MK_XBUTTON6 0x0400
#endif
#ifndef MK_XBUTTON7
#define MK_XBUTTON7 0x0800 #define MK_XBUTTON7 0x0800
#endif #endif

View File

@ -37,12 +37,24 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#endif #endif
#ifndef MK_XBUTTON1 #ifndef MK_XBUTTON1
#define MK_XBUTTON1 0x0020 #define MK_XBUTTON1 0x0020
#endif
#ifndef MK_XBUTTON2
#define MK_XBUTTON2 0x0040 #define MK_XBUTTON2 0x0040
#endif
// copied from DarkPlaces in an attempt to grab more buttons // copied from DarkPlaces in an attempt to grab more buttons
#ifndef MK_XBUTTON3
#define MK_XBUTTON3 0x0080 #define MK_XBUTTON3 0x0080
#endif
#ifndef MK_XBUTTON4
#define MK_XBUTTON4 0x0100 #define MK_XBUTTON4 0x0100
#endif
#ifndef MK_XBUTTON5
#define MK_XBUTTON5 0x0200 #define MK_XBUTTON5 0x0200
#endif
#ifndef MK_XBUTTON6
#define MK_XBUTTON6 0x0400 #define MK_XBUTTON6 0x0400
#endif
#ifndef MK_XBUTTON7
#define MK_XBUTTON7 0x0800 #define MK_XBUTTON7 0x0800
#endif #endif

View File

@ -51,12 +51,24 @@ extern int r_flushcache;
#endif #endif
#ifndef MK_XBUTTON1 #ifndef MK_XBUTTON1
#define MK_XBUTTON1 0x0020 #define MK_XBUTTON1 0x0020
#endif
#ifndef MK_XBUTTON2
#define MK_XBUTTON2 0x0040 #define MK_XBUTTON2 0x0040
#endif
// copied from DarkPlaces in an attempt to grab more buttons // copied from DarkPlaces in an attempt to grab more buttons
#ifndef MK_XBUTTON3
#define MK_XBUTTON3 0x0080 #define MK_XBUTTON3 0x0080
#endif
#ifndef MK_XBUTTON4
#define MK_XBUTTON4 0x0100 #define MK_XBUTTON4 0x0100
#endif
#ifndef MK_XBUTTON5
#define MK_XBUTTON5 0x0200 #define MK_XBUTTON5 0x0200
#endif
#ifndef MK_XBUTTON6
#define MK_XBUTTON6 0x0400 #define MK_XBUTTON6 0x0400
#endif
#ifndef MK_XBUTTON7
#define MK_XBUTTON7 0x0800 #define MK_XBUTTON7 0x0800
#endif #endif