hhctrl.ocx: Simplify extracting the help filename (Coverity).
[wine.git] / include / dbt.h
blobec8c084738338bd3e6fc06babe7e61204b399a20
1 /*
2 * Copyright (C) 2004 Ulrich Czekalla
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19 #ifndef __WINE_DBT_H
20 #define __WINE_DBT_H
22 #ifndef GUID_DEFINED
23 # include <guiddef.h>
24 #endif
26 /* dbt.h doesn't use the normal convention, it adds an underscore before A/W */
27 #ifdef WINE_NO_UNICODE_MACROS
28 # define DECL_WINELIB_DBT_TYPE_AW(type) /* nothing */
29 #else
30 # define DECL_WINELIB_DBT_TYPE_AW(type) typedef WINELIB_NAME_AW(type##_) type;
31 #endif
33 #define DBT_DEVNODES_CHANGED 0x0007
34 #define DBT_QUERYCHANGECONFIG 0x0017
35 #define DBT_CONFIGCHANGED 0x0018
36 #define DBT_CONFIGCHANGECANCELED 0x0019
37 #define DBT_NO_DISK_SPACE 0x0047
38 #define DBT_LOW_DISK_SPACE 0x0048
39 #define DBT_CONFIGMGPRIVATE 0x7FFF
40 #define DBT_DEVICEARRIVAL 0x8000
41 #define DBT_DEVICEQUERYREMOVE 0x8001
42 #define DBT_DEVICEQUERYREMOVEFAILED 0x8002
43 #define DBT_DEVICEREMOVEPENDING 0x8003
44 #define DBT_DEVICEREMOVECOMPLETE 0x8004
45 #define DBT_DEVICETYPESPECIFIC 0x8005
46 #define DBT_CUSTOMEVENT 0x8006
48 typedef struct _DEV_BROADCAST_HDR
50 DWORD dbch_size;
51 DWORD dbch_devicetype;
52 DWORD dbch_reserved;
53 } DEV_BROADCAST_HDR, *PDEV_BROADCAST_HDR;
55 #define DBT_DEVTYP_OEM 0x00000000
56 #define DBT_DEVTYP_DEVNODE 0x00000001
57 #define DBT_DEVTYP_VOLUME 0x00000002
58 #define DBT_DEVTYP_PORT 0x00000003
59 #define DBT_DEVTYP_NET 0x00000004
60 #define DBT_DEVTYP_DEVICEINTERFACE 0x00000005
61 #define DBT_DEVTYP_HANDLE 0x00000006
63 typedef struct _DEV_BROADCAST_OEM
65 DWORD dbco_size;
66 DWORD dbco_devicetype;
67 DWORD dbco_reserved;
68 DWORD dbco_identifier;
69 DWORD dbco_suppfunc;
70 } DEV_BROADCAST_OEM, *PDEV_BROADCAST_OEM;
72 typedef struct _DEV_BROADCAST_DEVNODE
74 DWORD dbcd_size;
75 DWORD dbcd_devicetype;
76 DWORD dbcd_reserved;
77 DWORD dbcd_devnode;
78 } DEV_BROADCAST_DEVNODE, *PDEV_BROADCAST_DEVNODE;
80 typedef struct _DEV_BROADCAST_VOLUME
82 DWORD dbcv_size;
83 DWORD dbcv_devicetype;
84 DWORD dbcv_reserved;
85 DWORD dbcv_unitmask;
86 WORD dbcv_flags;
87 } DEV_BROADCAST_VOLUME, *PDEV_BROADCAST_VOLUME;
89 #define DBTF_MEDIA 0x0001
90 #define DBTF_NET 0x0002
92 typedef struct _DEV_BROADCAST_PORT_A
94 DWORD dbcp_size;
95 DWORD dbcp_devicetype;
96 DWORD dbcp_reserved;
97 char dbcp_name[1];
98 } DEV_BROADCAST_PORT_A, *PDEV_BROADCAST_PORT_A;
100 typedef struct _DEV_BROADCAST_PORT_W
102 DWORD dbcp_size;
103 DWORD dbcp_devicetype;
104 DWORD dbcp_reserved;
105 WCHAR dbcp_name[1];
106 } DEV_BROADCAST_PORT_W, *PDEV_BROADCAST_PORT_W;
108 DECL_WINELIB_DBT_TYPE_AW(DEV_BROADCAST_PORT)
109 DECL_WINELIB_DBT_TYPE_AW(PDEV_BROADCAST_PORT)
111 typedef struct _DEV_BROADCAST_NET
113 DWORD dbcn_size;
114 DWORD dbcn_devicetype;
115 DWORD dbcn_reserved;
116 DWORD dbcn_resource;
117 DWORD dbcn_flags;
118 } DEV_BROADCAST_NET, *PDEV_BROADCAST_NET;
120 typedef struct _DEV_BROADCAST_DEVICEINTERFACE_A
122 DWORD dbcc_size;
123 DWORD dbcc_devicetype;
124 DWORD dbcc_reserved;
125 GUID dbcc_classguid;
126 CHAR dbcc_name[1];
127 } DEV_BROADCAST_DEVICEINTERFACE_A, *PDEV_BROADCAST_DEVICEINTERFACE_A;
129 typedef struct _DEV_BROADCAST_DEVICEINTERFACE_W
131 DWORD dbcc_size;
132 DWORD dbcc_devicetype;
133 DWORD dbcc_reserved;
134 GUID dbcc_classguid;
135 WCHAR dbcc_name[1];
136 } DEV_BROADCAST_DEVICEINTERFACE_W, *PDEV_BROADCAST_DEVICEINTERFACE_W;
138 DECL_WINELIB_DBT_TYPE_AW(DEV_BROADCAST_DEVICEINTERFACE)
139 DECL_WINELIB_DBT_TYPE_AW(PDEV_BROADCAST_DEVICEINTERFACE)
141 typedef struct _DEV_BROADCAST_HANDLE
143 DWORD dbch_size;
144 DWORD dbch_devicetype;
145 DWORD dbch_reserved;
146 HANDLE dbch_handle;
147 HDEVNOTIFY dbch_hdevnotify;
148 GUID dbch_eventguid;
149 LONG dbch_nameoffset;
150 BYTE dbch_data[1];
151 } DEV_BROADCAST_HANDLE, *PDEV_BROADCAST_HANDLE;
153 #undef DECL_WINELIB_DBT_TYPE_AW
155 #endif /* __WINE_DBT_H */