[DINPUT_WINETEST] Sync with Wine 3.0. CORE-14225
authorAmine Khaldi <amine.khaldi@reactos.org>
Sun, 21 Jan 2018 21:27:32 +0000 (22:27 +0100)
committerAmine Khaldi <amine.khaldi@reactos.org>
Sun, 21 Jan 2018 21:27:32 +0000 (22:27 +0100)
modules/rostests/winetests/dinput/mouse.c

index 5c7209c..791300d 100644 (file)
@@ -19,6 +19,7 @@
 
 #include "precomp.h"
 
+
 static const HRESULT SetCoop_null_window[16] =  {
     E_INVALIDARG, E_INVALIDARG, E_INVALIDARG, E_INVALIDARG,
     E_INVALIDARG, E_HANDLE,     E_HANDLE,     E_INVALIDARG,
@@ -82,7 +83,6 @@ static void test_acquire(IDirectInputA *pDI, HWND hwnd)
     DIPROPDWORD di_op;
     DIDEVICEOBJECTDATA mouse_state;
     DWORD cnt;
-    MSG msg;
     int i;
 
     if (! SetForegroundWindow(hwnd))
@@ -121,12 +121,9 @@ static void test_acquire(IDirectInputA *pDI, HWND hwnd)
     hwnd2 = CreateWindowA("static", "Temporary", WS_VISIBLE, 10, 210, 200, 200, NULL, NULL, NULL,
                           NULL);
     ok(hwnd2 != NULL, "CreateWindowA failed with %u\n", GetLastError());
-    while (PeekMessageA(&msg, 0, 0, 0, PM_REMOVE)) DispatchMessageA(&msg);
 
     hr = IDirectInputDevice_GetDeviceState(pMouse, sizeof(m_state), &m_state);
     ok(hr == DIERR_NOTACQUIRED, "GetDeviceState() should have failed: %08x\n", hr);
-    /* Workaround so we can test other things. Remove when Wine is fixed */
-    IDirectInputDevice_Unacquire(pMouse);
 
     hr = IDirectInputDevice_Acquire(pMouse);
     ok(hr == DIERR_OTHERAPPHASPRIO, "Acquire() should have failed: %08x\n", hr);