wined3d: Get rid of the WINED3DCUBEMAP_FACES typedef.
[wine] / include / werapi.h
1 /*
2  * Windows Error Reporting definitions
3  *
4  * Copyright (C) 2010 Louis Lenders
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with this library; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19  */
20
21 #ifndef __WINE_WERAPI_H
22 #define __WINE_WERAPI_H
23
24 #ifdef __cplusplus
25 extern "C" {
26 #endif
27
28 /* Only 10 parameter are allowed in WerReportSetParameter */
29 #define WER_MAX_PARAM_COUNT 10
30 #define WER_P0 0
31 #define WER_P1 1
32 #define WER_P2 2
33 #define WER_P3 3
34 #define WER_P4 4
35 #define WER_P5 5
36 #define WER_P6 6
37 #define WER_P7 7
38 #define WER_P8 8
39 #define WER_P9 9
40
41 /* Flags for WerReportSubmit */
42 #define WER_SUBMIT_HONOR_RECOVERY           0x0001
43 #define WER_SUBMIT_HONOR_RESTART            0x0002
44 #define WER_SUBMIT_QUEUE                    0x0004
45 #define WER_SUBMIT_SHOW_DEBUG               0x0008
46 #define WER_SUBMIT_ADD_REGISTERED_DATA      0x0010
47 #define WER_SUBMIT_OUTOFPROCESS             0x0020
48 #define WER_SUBMIT_NO_CLOSE_UI              0x0040
49 #define WER_SUBMIT_NO_QUEUE                 0x0080
50 #define WER_SUBMIT_NO_ARCHIVE               0x0100
51 #define WER_SUBMIT_START_MINIMIZED          0x0200
52 #define WER_SUBMIT_OUTOFPROCESS_ASYNC       0x0400
53 #define WER_SUBMIT_BYPASS_DATA_THROTTLING   0x0800
54 #define WER_SUBMIT_ARCHIVE_PARAMETERS_ONLY  0x1000
55 #define WER_SUBMIT_REPORT_MACHINE_ID        0x2000
56
57 #define WER_MAX_PREFERRED_MODULES           128
58 #define WER_MAX_PREFERRED_MODULES_BUFFER    256
59
60 /* #### */
61
62 typedef HANDLE HREPORT;
63
64 typedef enum _WER_CONSENT
65 {
66     WerConsentNotAsked = 1,
67     WerConsentApproved,
68     WerConsentDenied,
69     WerConsentAlwaysPrompt,
70     WerConsentMax
71 } WER_CONSENT;
72
73 typedef enum _WER_REGISTER_FILE_TYPE
74 {
75     WerRegFileTypeUserDocument = 1,
76     WerRegFileTypeOther = 2,
77     WerRegFileTypeMax
78 } WER_REGISTER_FILE_TYPE;
79
80 typedef struct _WER_REPORT_INFORMATION
81 {
82     DWORD   dwSize;
83     HANDLE  hProcess;
84     WCHAR   wzConsentKey[64];
85     WCHAR   wzFriendlyEventName[128];
86     WCHAR   wzApplicationName[128];
87     WCHAR   wzApplicationPath[MAX_PATH];
88     WCHAR   wzDescription[512];
89     HWND    hwndParent;
90 } WER_REPORT_INFORMATION, *PWER_REPORT_INFORMATION;
91
92
93 typedef enum _WER_REPORT_TYPE
94 {
95     WerReportNonCritical = 0,
96     WerReportCritical,
97     WerReportApplicationCrash,
98     WerReportApplicationHang,
99     WerReportKernel,
100     WerReportInvalid
101 } WER_REPORT_TYPE;
102
103 typedef enum _WER_SUBMIT_RESULT
104 {
105     WerReportQueued = 1,
106     WerReportUploaded,
107     WerReportDebug,
108     WerReportFailed,
109     WerDisabled,
110     WerReportCancelled,
111     WerDisabledQueue,
112     WerReportAsync,
113     WerCustomAction
114 } WER_SUBMIT_RESULT, *PWER_SUBMIT_RESULT;
115
116 typedef enum _WER_DUMP_TYPE
117 {
118     WerDumpTypeMicroDump = 1,
119     WerDumpTypeMiniDump,
120     WerDumpTypeHeapDump,
121     WerDumpTypeMax
122 } WER_DUMP_TYPE;
123
124 /* #### */
125
126 typedef struct _WER_DUMP_CUSTOM_OPTIONS
127 {
128     DWORD dwSize;
129     DWORD dwMask;
130     DWORD dwDumpFlags;
131     BOOL  bOnlyThisThread;
132     DWORD dwExceptionThreadFlags;
133     DWORD dwOtherThreadFlags;
134     DWORD dwExceptionThreadExFlags;
135     DWORD dwOtherThreadExFlags;
136     DWORD dwPreferredModuleFlags;
137     DWORD dwOtherModuleFlags;
138     WCHAR wzPreferredModuleList[WER_MAX_PREFERRED_MODULES_BUFFER];
139
140 } WER_DUMP_CUSTOM_OPTIONS, *PWER_DUMP_CUSTOM_OPTIONS;
141
142 typedef struct _WER_EXCEPTION_INFORMATION
143 {
144     PEXCEPTION_POINTERS pExceptionPointers;
145     BOOL bClientPointers;
146 } WER_EXCEPTION_INFORMATION, *PWER_EXCEPTION_INFORMATION;
147
148 /* #### */
149
150 HRESULT WINAPI WerAddExcludedApplication(PCWSTR, BOOL);
151 HRESULT WINAPI WerRegisterFile(PCWSTR file, WER_REGISTER_FILE_TYPE regfiletype, DWORD flags);
152 HRESULT WINAPI WerRemoveExcludedApplication(PCWSTR, BOOL);
153 HRESULT WINAPI WerReportCloseHandle(HREPORT);
154 HRESULT WINAPI WerReportCreate(PCWSTR, WER_REPORT_TYPE, PWER_REPORT_INFORMATION, HREPORT*);
155 HRESULT WINAPI WerReportSetParameter(HREPORT, DWORD, PCWSTR, PCWSTR);
156 HRESULT WINAPI WerReportSubmit(HREPORT, WER_CONSENT, DWORD, PWER_SUBMIT_RESULT);
157
158 #ifdef __cplusplus
159 }
160 #endif
161
162 #endif /* __WINE_WERAPI_H */