[DINPUT_WINETEST] Add a PCH.
authorAmine Khaldi <amine.khaldi@reactos.org>
Thu, 21 Dec 2017 12:45:22 +0000 (13:45 +0100)
committerAmine Khaldi <amine.khaldi@reactos.org>
Thu, 21 Dec 2017 12:45:22 +0000 (13:45 +0100)
modules/rostests/winetests/dinput/CMakeLists.txt
modules/rostests/winetests/dinput/device.c
modules/rostests/winetests/dinput/dinput.c
modules/rostests/winetests/dinput/joystick.c
modules/rostests/winetests/dinput/keyboard.c
modules/rostests/winetests/dinput/mouse.c
modules/rostests/winetests/dinput/precomp.h [new file with mode: 0644]

index 72cc31f..58bec04 100644 (file)
@@ -1,15 +1,17 @@
 
 add_definitions(-DUSE_WINE_TODOS)
 
-add_executable(dinput_winetest
+list(APPEND SOURCE
     device.c
     dinput.c
     joystick.c
     keyboard.c
     mouse.c
-    testlist.c)
+    precomp.h)
 
+add_executable(dinput_winetest ${SOURCE} testlist.c)
 target_link_libraries(dinput_winetest dinput_data_formats)
 set_module_type(dinput_winetest win32cui)
 add_importlibs(dinput_winetest dinput ole32 user32 msvcrt kernel32)
+add_pch(dinput_winetest precomp.h SOURCE)
 add_rostests_file(TARGET dinput_winetest)
index 20d211d..605b091 100644 (file)
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#define WIN32_NO_STATUS
-#define _INC_WINDOWS
-#define COM_NO_WINDOWS_H
-
-#define DIRECTINPUT_VERSION 0x0700
-
-#define COBJMACROS
-//#include <windows.h>
-
-#include <wine/test.h>
-//#include "windef.h"
-#include <dinput.h>
+#include "precomp.h"
 
 static const DIOBJECTDATAFORMAT obj_data_format[] = {
   { &GUID_YAxis, 16, DIDFT_OPTIONAL|DIDFT_AXIS  |DIDFT_MAKEINSTANCE(1), 0},
index 54de5d0..b4f3640 100644 (file)
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#define WIN32_NO_STATUS
-#define _INC_WINDOWS
-#define COM_NO_WINDOWS_H
+#include "precomp.h"
 
-#define DIRECTINPUT_VERSION 0x0700
-
-#define COBJMACROS
-
-#include <wine/test.h>
-
-#include <initguid.h>
-//#include <windows.h>
-#include <dinput.h>
 #include <dinputd.h>
 
 HINSTANCE hInstance;
index 28b70bc..6649023 100644 (file)
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#define WIN32_NO_STATUS
-#define _INC_WINDOWS
-#define COM_NO_WINDOWS_H
+#include "precomp.h"
 
-#define DIRECTINPUT_VERSION 0x0700
-
-#define COBJMACROS
-//#include <windows.h>
-
-//#include <math.h>
 #include <stdio.h>
-//#include <stdlib.h>
-
-#include <wine/test.h>
-//#include "windef.h"
-//#include "wingdi.h"
 #include <winnls.h>
-#include <dinput.h>
 
 #define numObjects(x) (sizeof(x) / sizeof(x[0]))
 
index 18e1f07..6df1028 100644 (file)
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#define WIN32_NO_STATUS
-#define _INC_WINDOWS
-#define COM_NO_WINDOWS_H
-
-#define DIRECTINPUT_VERSION 0x0700
-
-#define COBJMACROS
-//#include <windows.h>
-
-//#include <math.h>
-//#include <stdio.h>
-//#include <stdlib.h>
-
-#include <wine/test.h>
-//#include "windef.h"
-//#include "wingdi.h"
-#include <dinput.h>
+#include "precomp.h"
 
 static void acquire_tests(IDirectInputA *pDI, HWND hwnd)
 {
index 8463c16..5c7209c 100644 (file)
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#define WIN32_NO_STATUS
-#define _INC_WINDOWS
-#define COM_NO_WINDOWS_H
-
-#define DIRECTINPUT_VERSION 0x0700
-
-#define COBJMACROS
-//#include <windows.h>
-
-//#include <math.h>
-//#include <stdlib.h>
-
-#include <wine/test.h>
-//#include "windef.h"
-//#include "wingdi.h"
-#include <dinput.h>
+#include "precomp.h"
 
 static const HRESULT SetCoop_null_window[16] =  {
     E_INVALIDARG, E_INVALIDARG, E_INVALIDARG, E_INVALIDARG,
diff --git a/modules/rostests/winetests/dinput/precomp.h b/modules/rostests/winetests/dinput/precomp.h
new file mode 100644 (file)
index 0000000..131fdab
--- /dev/null
@@ -0,0 +1,17 @@
+#ifndef _DINPUT_WINETEST_PRECOMP_H_
+#define _DINPUT_WINETEST_PRECOMP_H_
+
+#define WIN32_NO_STATUS
+#define _INC_WINDOWS
+#define COM_NO_WINDOWS_H
+
+#define DIRECTINPUT_VERSION 0x0700
+
+#define COBJMACROS
+
+#include <wine/test.h>
+
+#include <initguid.h>
+#include <dinput.h>
+
+#endif /* !_DINPUT_WINETEST_PRECOMP_H_ */