Got rid of CLIENT_GetProcessInfo.
[wine/multimedia.git] / include / shell.h
blobc19af4954ef2a30dfaeae3677078d2ab16c81aac
1 /*
2 * Shell Library definitions
3 */
4 #ifndef __WINE_SHELL_H
5 #define __WINE_SHELL_H
7 #include "wintypes.h"
8 #include "winreg.h"
9 #include "imagelist.h"
11 #ifndef MAX_PATH
12 #define MAX_PATH 260
13 #endif
15 /****************************************************************************
16 * shell 16
18 extern void SHELL_LoadRegistry(void);
19 extern void SHELL_SaveRegistry(void);
20 extern void SHELL_Init(void);
22 /* global functions used from shell32 */
23 extern HINSTANCE32 SHELL_FindExecutable(LPCSTR,LPCSTR ,LPSTR);
24 extern HGLOBAL16 WINAPI InternalExtractIcon(HINSTANCE16,LPCSTR,UINT16,WORD);
26 /****************************************************************************
27 * shell 32
29 /****************************************************************************
30 * common return codes
32 #define SHELL_ERROR_SUCCESS 0L
33 #define SHELL_ERROR_BADDB 1L
34 #define SHELL_ERROR_BADKEY 2L
35 #define SHELL_ERROR_CANTOPEN 3L
36 #define SHELL_ERROR_CANTREAD 4L
37 #define SHELL_ERROR_CANTWRITE 5L
38 #define SHELL_ERROR_OUTOFMEMORY 6L
39 #define SHELL_ERROR_INVALID_PARAMETER 7L
40 #define SHELL_ERROR_ACCESS_DENIED 8L
42 /****************************************************************************
43 * common shell file structures
45 #define FO_MOVE 0x0001
46 #define FO_COPY 0x0002
47 #define FO_DELETE 0x0003
48 #define FO_RENAME 0x0004
50 #define FOF_MULTIDESTFILES 0x0001
51 #define FOF_CONFIRMMOUSE 0x0002
52 #define FOF_SILENT 0x0004
53 #define FOF_RENAMEONCOLLISION 0x0008
54 #define FOF_NOCONFIRMATION 0x0010
55 #define FOF_WANTMAPPINGHANDLE 0x0020
56 #define FOF_ALLOWUNDO 0x0040
57 #define FOF_FILESONLY 0x0080
58 #define FOF_SIMPLEPROGRESS 0x0100
59 #define FOF_NOCONFIRMMKDIR 0x0200
60 #define FOF_NOERRORUI 0x0400
62 typedef WORD FILEOP_FLAGS;
64 #define PO_DELETE 0x0013
65 #define PO_RENAME 0x0014
66 #define PO_PORTCHANGE 0x0020
68 typedef WORD PRINTEROP_FLAGS;
70 /******************************
71 * DRAG&DROP API
73 typedef struct { /* structure for dropped files */
74 WORD wSize;
75 POINT16 ptMousePos;
76 BOOL16 fInNonClientArea;
77 /* memory block with filenames follows */
78 } DROPFILESTRUCT16, *LPDROPFILESTRUCT16;
80 typedef struct { /* structure for dropped files */
81 DWORD lSize;
82 POINT32 ptMousePos;
83 BOOL32 fInNonClientArea;
84 BOOL32 fWideChar;
85 /* memory block with filenames follows */
86 } DROPFILESTRUCT32, *LPDROPFILESTRUCT32;
88 DECL_WINELIB_TYPE(DROPFILESTRUCT)
89 DECL_WINELIB_TYPE(LPDROPFILESTRUCT)
91 void WINAPI DragAcceptFiles16(HWND16 hWnd, BOOL16 b);
92 void WINAPI DragAcceptFiles32(HWND32 hWnd, BOOL32 b);
93 #define DragAcceptFiles WINELIB_NAME(DragAcceptFiles)
94 UINT16 WINAPI DragQueryFile16(HDROP16 hDrop, WORD wFile, LPSTR lpszFile, WORD wLength);
95 UINT32 WINAPI DragQueryFile32A(HDROP32 hDrop, UINT32 lFile, LPSTR lpszFile, UINT32 lLength);
96 UINT32 WINAPI DragQueryFile32W(HDROP32 hDrop, UINT32 lFile, LPWSTR lpszFile, UINT32 lLength);
97 #define DragQueryFile WINELIB_NAME_AW(DragQueryFile)
98 void WINAPI DragFinish32(HDROP32 h);
99 void WINAPI DragFinish16(HDROP16 h);
100 #define DragFinish WINELIB_NAME(DragFinish)
101 BOOL32 WINAPI DragQueryPoint32(HDROP32 hDrop, POINT32 *p);
102 BOOL16 WINAPI DragQueryPoint16(HDROP16 hDrop, POINT16 *p);
103 #define DragQueryPoint WINELIB_NAME(DragQueryPoint)
106 /****************************************************************************
107 * NOTIFYICONDATA
109 typedef struct _NOTIFYICONDATA {
110 DWORD cbSize;
111 HWND32 hWnd;
112 UINT32 uID;
113 UINT32 uFlags;
114 UINT32 uCallbackMessage;
115 HICON32 hIcon;
116 CHAR szTip[64];
117 } NOTIFYICONDATA, *PNOTIFYICONDATA;
119 /****************************************************************************
120 * SHITEMID, ITEMIDLIST, PIDL API
122 #pragma pack(1)
123 typedef struct
124 { WORD cb; /* nr of bytes in this item */
125 BYTE abID[1];/* first byte in this item */
126 } SHITEMID,*LPSHITEMID;
128 typedef struct
129 { SHITEMID mkid; /* first itemid in list */
130 } ITEMIDLIST,*LPITEMIDLIST,*LPCITEMIDLIST;
131 #pragma pack(4)
133 DWORD WINAPI SHGetPathFromIDList32A (LPCITEMIDLIST pidl,LPSTR pszPath);
134 DWORD WINAPI SHGetPathFromIDList32W (LPCITEMIDLIST pidl,LPWSTR pszPath);
135 #define SHGetPathFromIDList WINELIB_NAME_AW(SHGetPathFromIDList)
137 /****************************************************************************
138 * SHFILEINFO API
140 typedef struct tagSHFILEINFO32A {
141 HICON32 hIcon; /* icon */
142 int iIcon; /* icon index */
143 DWORD dwAttributes; /* SFGAO_ flags */
144 CHAR szDisplayName[MAX_PATH];/* display name (or path) */
145 CHAR szTypeName[80]; /* type name */
146 } SHFILEINFO32A;
148 typedef struct tagSHFILEINFO32W {
149 HICON32 hIcon; /* icon */
150 int iIcon; /* icon index */
151 DWORD dwAttributes; /* SFGAO_ flags */
152 WCHAR szDisplayName[MAX_PATH];/* display name (or path) */
153 WCHAR szTypeName[80]; /* type name */
154 } SHFILEINFO32W;
156 DECL_WINELIB_TYPE_AW(SHFILEINFO)
158 DWORD WINAPI SHGetFileInfo32A(LPCSTR,DWORD,SHFILEINFO32A*,UINT32,UINT32);
159 DWORD WINAPI SHGetFileInfo32W(LPCWSTR,DWORD,SHFILEINFO32W*,UINT32,UINT32);
160 #define SHGetFileInfo WINELIB_NAME_AW(SHGetFileInfo)
162 /****************************************************************************
163 * SHFILEOPSTRUCT API
165 typedef struct _SHFILEOPSTRUCTA
166 { HWND32 hwnd;
167 UINT32 wFunc;
168 LPCSTR pFrom;
169 LPCSTR pTo;
170 FILEOP_FLAGS fFlags;
171 BOOL32 fAnyOperationsAborted;
172 LPVOID hNameMappings;
173 LPCSTR lpszProgressTitle;
174 } SHFILEOPSTRUCT32A, *LPSHFILEOPSTRUCT32A;
176 typedef struct _SHFILEOPSTRUCTW
177 { HWND32 hwnd;
178 UINT32 wFunc;
179 LPCWSTR pFrom;
180 LPCWSTR pTo;
181 FILEOP_FLAGS fFlags;
182 BOOL32 fAnyOperationsAborted;
183 LPVOID hNameMappings;
184 LPCWSTR lpszProgressTitle;
185 } SHFILEOPSTRUCT32W, *LPSHFILEOPSTRUCT32W;
187 #define SHFILEOPSTRUCT WINELIB_NAME_AW(SHFILEOPSTRUCT)
188 #define LPSHFILEOPSTRUCT WINELIB_NAME_AW(LPSHFILEOPSTRUCT)
190 DWORD WINAPI SHFileOperation32A (LPSHFILEOPSTRUCT32A lpFileOp);
191 DWORD WINAPI SHFileOperation32W (LPSHFILEOPSTRUCT32W lpFileOp);
192 #define SHFileOperation WINELIB_NAME_AW(SHFileOperation)
194 DWORD WINAPI SHFileOperation32(DWORD x);
196 /****************************************************************************
197 * APPBARDATA
199 typedef struct _AppBarData {
200 DWORD cbSize;
201 HWND32 hWnd;
202 UINT32 uCallbackMessage;
203 UINT32 uEdge;
204 RECT32 rc;
205 LPARAM lParam;
206 } APPBARDATA, *PAPPBARDATA;
208 #define SHGFI_ICON 0x000000100 /* get icon */
209 #define SHGFI_DISPLAYNAME 0x000000200 /* get display name */
210 #define SHGFI_TYPENAME 0x000000400 /* get type name */
211 #define SHGFI_ATTRIBUTES 0x000000800 /* get attributes */
212 #define SHGFI_ICONLOCATION 0x000001000 /* get icon location */
213 #define SHGFI_EXETYPE 0x000002000 /* return exe type */
214 #define SHGFI_SYSICONINDEX 0x000004000 /* get system icon index */
215 #define SHGFI_LINKOVERLAY 0x000008000 /* put a link overlay on icon */
216 #define SHGFI_SELECTED 0x000010000 /* show icon in selected state */
217 #define SHGFI_LARGEICON 0x000000000 /* get large icon */
218 #define SHGFI_SMALLICON 0x000000001 /* get small icon */
219 #define SHGFI_OPENICON 0x000000002 /* get open icon */
220 #define SHGFI_SHELLICONSIZE 0x000000004 /* get shell size icon */
221 #define SHGFI_PIDL 0x000000008 /* pszPath is a pidl */
222 #define SHGFI_USEFILEATTRIBUTES 0x000000010 /* use passed dwFileAttribute */
224 /****************************************************************************
225 * SHChangeNotifyRegister API
227 typedef struct
228 { LPITEMIDLIST pidl;
229 DWORD unknown;
230 } IDSTRUCT;
232 DWORD WINAPI SHChangeNotifyRegister(HWND32 hwnd,LONG events1,LONG events2,DWORD msg,int count,IDSTRUCT *idlist);
233 DWORD WINAPI SHChangeNotifyDeregister(LONG x1);
235 /****************************************************************************
236 * SHAddToRecentDocs API
238 #define SHARD_PIDL 0x00000001L
239 #define SHARD_PATH 0x00000002L
241 DWORD WINAPI SHAddToRecentDocs(UINT32 uFlags, LPCVOID pv);
243 /****************************************************************************
244 * SHGetSpecialFolderLocation API
246 HRESULT WINAPI SHGetSpecialFolderLocation(HWND32, INT32, LPITEMIDLIST *);
247 /****************************************************************************
248 * string and path functions
250 LPSTR WINAPI PathAddBackslash32A(LPSTR path);
251 LPWSTR WINAPI PathAddBackslash32W(LPWSTR path);
252 #define PathAddBackslash WINELIB_NAME_AW(PathAddBackslash)
253 LPVOID WINAPI PathAddBackslash32AW(LPVOID path);
255 LPSTR WINAPI PathQuoteSpaces32A(LPCSTR path);
256 LPWSTR WINAPI PathQuoteSpaces32W(LPCWSTR path);
257 #define PathQuoteSpaces WINELIB_NAME_AW(PathQuoteSpaces)
258 LPVOID WINAPI PathQuoteSpaces32AW(LPCVOID path);
260 LPSTR WINAPI PathCombine32A(LPSTR szDest, LPCSTR lpszDir, LPCSTR lpszFile);
261 LPWSTR WINAPI PathCombine32W(LPWSTR szDest, LPCWSTR lpszDir, LPCWSTR lpszFile);
262 #define PathCombine WINELIB_NAME_AW(PathCombine)
263 LPVOID WINAPI PathCombine32AW(LPVOID szDest, LPCVOID lpszDir, LPCVOID lpszFile);
265 LPCSTR WINAPI PathFindExtension32A(LPCSTR path);
266 LPCWSTR WINAPI PathFindExtension32W(LPCWSTR path);
267 #define PathFindExtension WINELIB_NAME_AW(PathFindExtension)
268 LPCVOID WINAPI PathFindExtension32AW(LPCVOID path);
270 LPCSTR WINAPI PathGetExtension32A(LPCSTR path, DWORD y, DWORD x);
271 LPCWSTR WINAPI PathGetExtension32W(LPCWSTR path, DWORD y, DWORD x);
272 #define PathGetExtension WINELIB_NAME_AW(PathGetExtension)
273 LPCVOID WINAPI PathGetExtension32AW(LPCVOID path, DWORD y, DWORD x);
275 LPCSTR WINAPI PathFindFilename32A(LPCSTR path);
276 LPCWSTR WINAPI PathFindFilename32W(LPCWSTR path);
277 #define PathFindFilename WINELIB_NAME_AW(PathFindFilename)
278 LPCVOID WINAPI PathFindFilename32AW(LPCVOID path);
280 BOOL32 WINAPI PathMatchSpec32A(LPCSTR x, LPCSTR y);
281 BOOL32 WINAPI PathMatchSpec32W(LPCWSTR x, LPCWSTR y);
282 #define PathMatchSpec WINELIB_NAME_AW(PathMatchSpec)
283 BOOL32 WINAPI PathMatchSpec32AW(LPVOID x, LPVOID y);
285 LPSTR WINAPI PathRemoveBlanks32A(LPSTR str);
286 LPWSTR WINAPI PathRemoveBlanks32W(LPWSTR str);
287 #define PathRemoveBlanks WINELIB_NAME_AW(PathRemoveBlanks)
288 LPVOID WINAPI PathRemoveBlanks32AW(LPVOID str);
290 BOOL32 WINAPI PathIsRelative32A(LPCSTR str);
291 BOOL32 WINAPI PathIsRelative32W(LPCWSTR str);
292 #define PathIsRelative WINELIB_NAME_AW(PathIsRelative)
293 BOOL32 WINAPI PathIsRelative32AW(LPCVOID str);
295 BOOL32 WINAPI PathIsUNC32A(LPCSTR str);
296 BOOL32 WINAPI PathIsUNC32W(LPCWSTR str);
297 #define PathIsUNC WINELIB_NAME_AW(PathIsUNC)
298 BOOL32 WINAPI PathIsUNC32AW(LPCVOID str);
300 BOOL32 WINAPI PathFindOnPath32A(LPSTR sFile, LPCSTR sOtherDirs);
301 BOOL32 WINAPI PathFindOnPath32W(LPWSTR sFile, LPCWSTR sOtherDirs);
302 #define PathFindOnPath WINELIB_NAME_AW(PathFindOnPath)
303 BOOL32 WINAPI PathFindOnPath32AW(LPVOID sFile, LPCVOID sOtherDirs);
305 LPSTR WINAPI StrFormatByteSize32A ( DWORD dw, LPSTR pszBuf, UINT32 cchBuf );
306 LPWSTR WINAPI StrFormatByteSize32W ( DWORD dw, LPWSTR pszBuf, UINT32 cchBuf );
307 #define StrFormatByteSize WINELIB_NAME_AW(StrFormatByteSize)
309 /****************************************************************************
310 * other functions
312 HICON32 WINAPI ExtractIconEx32A ( LPSTR, INT32, HICON32 *, HICON32 *, UINT32 );
313 HICON32 WINAPI ExtractIconEx32W ( LPWSTR, INT32, HICON32 *, HICON32 *, UINT32 );
314 #define ExtractIconEx WINELIB_NAME_AW(ExtractIconEx)
315 HICON32 WINAPI ExtractIconEx32AW ( LPVOID, INT32, HICON32 *, HICON32 *, UINT32 );
317 LPVOID WINAPI SHAlloc(DWORD len);
318 DWORD WINAPI SHFree(LPVOID x);
320 #define SE_ERR_SHARE 26
321 #define SE_ERR_ASSOCINCOMPLETE 27
322 #define SE_ERR_DDETIMEOUT 28
323 #define SE_ERR_DDEFAIL 29
324 #define SE_ERR_DDEBUSY 30
325 #define SE_ERR_NOASSOC 31
327 #define CSIDL_DESKTOP 0x0000
328 #define CSIDL_PROGRAMS 0x0002
329 #define CSIDL_CONTROLS 0x0003
330 #define CSIDL_PRINTERS 0x0004
331 #define CSIDL_PERSONAL 0x0005
332 #define CSIDL_FAVORITES 0x0006
333 #define CSIDL_STARTUP 0x0007
334 #define CSIDL_RECENT 0x0008
335 #define CSIDL_SENDTO 0x0009
336 #define CSIDL_BITBUCKET 0x000a
337 #define CSIDL_STARTMENU 0x000b
338 #define CSIDL_DESKTOPDIRECTORY 0x0010
339 #define CSIDL_DRIVES 0x0011
340 #define CSIDL_NETWORK 0x0012
341 #define CSIDL_NETHOOD 0x0013
342 #define CSIDL_FONTS 0x0014
343 #define CSIDL_TEMPLATES 0x0015
344 #define CSIDL_COMMON_STARTMENU 0x0016
345 #define CSIDL_COMMON_PROGRAMS 0X0017
346 #define CSIDL_COMMON_STARTUP 0x0018
347 #define CSIDL_COMMON_DESKTOPDIRECTORY 0x0019
348 #define CSIDL_APPDATA 0x001a
349 #define CSIDL_PRINTHOOD 0x001b
352 #endif /* __WINE_SHELL_H */