Create the AHCI branch for Aman's work
[reactos.git] / base / applications / dxdiag / precomp.h
1 #ifndef PRECOMP_H__
2 #define PRECOMP_H__
3
4 #define DIRECTINPUT_VERSION 0x0800
5 #define DIRECTSOUND_VERSION 0x0800
6 #define D3D_OVERLOADS
7
8 #include <stdarg.h>
9
10 #define WIN32_NO_STATUS
11 #define _INC_WINDOWS
12 #define COM_NO_WINDOWS_H
13 #include <stdarg.h>
14 #include <windef.h>
15 #include <winbase.h>
16 #include <winreg.h>
17 #include <wingdi.h>
18 #include <winnls.h>
19 #include <winuser.h>
20 #include <setupapi.h>
21 #include <ddraw.h>
22 #include <initguid.h>
23 #include <devguid.h>
24 #include <strsafe.h>
25
26 #include "resource.h"
27
28 typedef struct
29 {
30 HWND hMainDialog;
31 HWND hTabCtrl;
32 ULONG NumDisplayAdapter;
33 HWND * hDisplayWnd;
34 ULONG NumSoundAdapter;
35 HWND * hSoundWnd;
36 HWND hDialogs[5];
37 }DXDIAG_CONTEXT, *PDXDIAG_CONTEXT;
38
39 /* globals */
40 extern HINSTANCE hInst;
41
42 /* theming hack */
43 BOOL EnableDialogTheme(HWND hwnd);
44
45 /* dialog wnd proc */
46 INT_PTR CALLBACK SystemPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
47 INT_PTR CALLBACK DisplayPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
48 INT_PTR CALLBACK SoundPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
49 INT_PTR CALLBACK MusicPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
50 INT_PTR CALLBACK InputPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
51 INT_PTR CALLBACK NetworkPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
52 INT_PTR CALLBACK HelpPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
53
54 /* DirectDraw tests */
55 VOID DDTests(VOID);
56
57 /* Direct3D tests */
58 VOID D3DTests(VOID);
59
60 /* DirectSound initialization */
61 void InitializeDirectSoundPage(PDXDIAG_CONTEXT pContext);
62
63 /* display adapter initialization */
64 void InitializeDisplayAdapters(PDXDIAG_CONTEXT pContext);
65
66 /* general functions */
67 BOOL GetFileVersion(LPCWSTR szAppName, WCHAR * szVer, DWORD szVerSize);
68 BOOL GetFileModifyTime(LPCWSTR pFullPath, WCHAR * szTime, int szTimeSize);
69 BOOL GetCatFileFromDriverPath(LPWSTR szFileName, LPWSTR szCatFileName);
70 BOOL GetRegValue(HKEY hBaseKey, LPWSTR SubKey, LPWSTR ValueName, DWORD Type, LPWSTR Result, DWORD Size);
71 VOID InsertTabCtrlItem(HWND hDlgCtrl, INT Position, LPWSTR uId);
72 VOID EnumerateDrivers(PVOID Context, HDEVINFO hList, PSP_DEVINFO_DATA pInfoData);
73
74 #endif /* PRECOMP_H__ */