From 18f604dad6dc189fd91c76c6839f27cdd7d02556 Mon Sep 17 00:00:00 2001 From: pagefault <> Date: Mon, 18 Jun 2001 00:40:47 +0000 Subject: [PATCH] Changed some DirectInput code from C to C++ syntax --- zsnes/src/win/winlink.cpp | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/zsnes/src/win/winlink.cpp b/zsnes/src/win/winlink.cpp index 9b542722..522ac0fa 100644 --- a/zsnes/src/win/winlink.cpp +++ b/zsnes/src/win/winlink.cpp @@ -1020,10 +1020,10 @@ void TestJoy() { JoystickInput[i]->Poll(); - if (IDirectInputDevice8_GetDeviceState(JoystickInput[i],sizeof(DIJOYSTATE), &js[i])==DIERR_INPUTLOST) + if (JoystickInput[i]->GetDeviceState(sizeof(DIJOYSTATE), &js[i])==DIERR_INPUTLOST) { if (JoystickInput[i]) JoystickInput[i]->Acquire(); - if (FAILED(IDirectInputDevice8_GetDeviceState(JoystickInput[i],sizeof(DIJOYSTATE), &js[i]))) return; + if (FAILED(JoystickInput[i]->GetDeviceState(sizeof(DIJOYSTATE), &js[i]))) return; } if (!X1Disable[i]) @@ -2204,11 +2204,9 @@ void drawscreenwin(void) initwinvideo(); Sleep(1000); drawscreenwin(); -// exit(0); } } - UnlockSurface(); } @@ -2280,10 +2278,10 @@ void WinUpdateDevices() JoystickInput[i]->Poll(); - if (IDirectInputDevice8_GetDeviceState(JoystickInput[i],sizeof(DIJOYSTATE), &js[i])==DIERR_INPUTLOST) + if (JoystickInput[i]->GetDeviceState(sizeof(DIJOYSTATE), &js[i])==DIERR_INPUTLOST) { if (JoystickInput[i]) JoystickInput[i]->Acquire(); - if (FAILED(IDirectInputDevice8_GetDeviceState(JoystickInput[i],sizeof(DIJOYSTATE), &js[i]))) return; + if (FAILED(JoystickInput[i]->GetDeviceState(sizeof(DIJOYSTATE), &js[i]))) return; } if (!X1Disable[i])