[PSDK] Fix a typo.
[reactos.git] / reactos / include / psdk / shobjidl.idl
1 /*
2 * COM interfaces for shell objects
3 *
4 * Copyright (C) 1999 Juergen Schmied
5 * Copyright (C) 2003 Alexandre Julliard
6 *
7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Lesser General Public
9 * License as published by the Free Software Foundation; either
10 * version 2.1 of the License, or (at your option) any later version.
11 *
12 * This library is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * Lesser General Public License for more details.
16 *
17 * You should have received a copy of the GNU Lesser General Public
18 * License along with this library; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
20 */
21
22 import "objidl.idl";
23 import "oleidl.idl";
24 import "oaidl.idl";
25 import "docobj.idl";
26 import "shtypes.idl";
27 import "servprov.idl";
28 import "comcat.idl";
29 import "propidl.idl";
30 /* FIXME: import "prsht.idl";*/
31 import "msxml.idl";
32 import "wtypes.idl";
33 import "propsys.idl";
34 import "objectarray.idl";
35 /* FIXME: import "structuredquery.idl"; */
36
37 cpp_quote("/* FIXME: #include <sherrors.h> */")
38
39
40 /*****************************************************************************
41 * IPersistFolder interface
42 */
43 [
44 object,
45 uuid(000214ea-0000-0000-c000-000000000046),
46 pointer_default(unique)
47 ]
48 interface IPersistFolder : IPersist
49 {
50 typedef IPersistFolder *LPPERSISTFOLDER;
51
52 HRESULT Initialize( [in] LPCITEMIDLIST pidl );
53 }
54
55
56 /*****************************************************************************
57 * IPersistFolder2 interface
58 */
59 [
60 object,
61 uuid(1ac3d9f0-175c-11d1-95be-00609797ea4f),
62 pointer_default(unique)
63 ]
64 interface IPersistFolder2 : IPersistFolder
65 {
66 typedef IPersistFolder2 *LPPERSISTFOLDER2;
67
68 HRESULT GetCurFolder( [out] LPITEMIDLIST *ppidl );
69 }
70
71
72 /*****************************************************************************
73 * IPersistIDList interface
74 */
75 [
76 object,
77 uuid(1079acfc-29bd-11d3-8e0d-00c04f6837d5),
78 pointer_default(unique)
79 ]
80 interface IPersistIDList : IPersist
81 {
82 HRESULT SetIDList( [in] LPCITEMIDLIST pidl );
83 HRESULT GetIDList( [out] LPITEMIDLIST *ppidl );
84 }
85
86
87 /*****************************************************************************
88 * IEnumIDList interface
89 */
90 [
91 object,
92 uuid(000214f2-0000-0000-c000-000000000046),
93 pointer_default(unique)
94 ]
95 interface IEnumIDList : IUnknown
96 {
97 typedef IEnumIDList *LPENUMIDLIST;
98
99 HRESULT Next(
100 [in] ULONG celt,
101 [out, size_is(celt), length_is(*pceltFetched)] LPITEMIDLIST *rgelt,
102 [out] ULONG *pceltFetched);
103
104 HRESULT Skip( [in] ULONG celt );
105 HRESULT Reset();
106 HRESULT Clone( [out] IEnumIDList **ppenum );
107 }
108
109 /*****************************************************************************
110 * IShellPropSheetExt interface
111 */
112 cpp_quote("#if 0")
113 typedef LPARAM LPFNSVADDPROPSHEETPAGE;
114 cpp_quote("#else")
115 cpp_quote("#include <prsht.h>")
116 cpp_quote("typedef LPFNADDPROPSHEETPAGE LPFNSVADDPROPSHEETPAGE;")
117 cpp_quote("#endif")
118
119 [
120 object,
121 uuid(000214E9-0000-0000-C000-000000000046),
122 pointer_default(unique),
123 local
124 ]
125 interface IShellPropSheetExt : IUnknown
126 {
127 enum tagSHELLPROPSHEETEXTPAGEID {
128 EXPPS_FILETYPES = 0x1
129 };
130
131 typedef UINT EXPPS;
132
133 HRESULT AddPages(
134 [in] LPFNSVADDPROPSHEETPAGE pfnAddPage,
135 [in] LPARAM lParam);
136 HRESULT ReplacePage(
137 [in] EXPPS uPageID,
138 [in] LPFNSVADDPROPSHEETPAGE pfnReplaceWith,
139 [in] LPARAM lParam);
140 }
141 typedef IShellPropSheetExt *LPSHELLPROPSHEETEXT;
142
143 /*****************************************************************************
144 * IShellFolder interface
145 */
146 [
147 object,
148 uuid(000214e6-0000-0000-c000-000000000046),
149 pointer_default(unique)
150 ]
151 interface IShellFolder : IUnknown
152 {
153 typedef IShellFolder * LPSHELLFOLDER;
154
155 typedef enum tagSHGDN
156 {
157 SHGDN_NORMAL = 0,
158 SHGDN_INFOLDER = 1,
159 SHGDN_FOREDITING = 0x1000,
160 SHGDN_INCLUDE_NONFILESYS = 0x2000,
161 SHGDN_FORADDRESSBAR = 0x4000,
162 SHGDN_FORPARSING = 0x8000
163 } SHGNO;
164
165 typedef DWORD SHGDNF;
166
167 enum tagSHCONTF
168 {
169 SHCONTF_FOLDERS = 32,
170 SHCONTF_NONFOLDERS = 64,
171 SHCONTF_INCLUDEHIDDEN = 128,
172 SHCONTF_INIT_ON_FIRST_NEXT = 256,
173 SHCONTF_NETPRINTERSRCH = 512,
174 SHCONTF_SHAREABLE = 1024,
175 SHCONTF_STORAGE = 2048
176 };
177
178 typedef DWORD SHCONTF;
179
180 cpp_quote("#define SFGAO_CANCOPY DROPEFFECT_COPY")
181 cpp_quote("#define SFGAO_CANMOVE DROPEFFECT_MOVE")
182 cpp_quote("#define SFGAO_CANLINK DROPEFFECT_LINK")
183 cpp_quote("#define SFGAO_STORAGE 0x00000008L")
184 cpp_quote("#define SFGAO_CANRENAME 0x00000010L")
185 cpp_quote("#define SFGAO_CANDELETE 0x00000020L")
186 cpp_quote("#define SFGAO_HASPROPSHEET 0x00000040L")
187 cpp_quote("#define SFGAO_DROPTARGET 0x00000100L")
188 cpp_quote("#define SFGAO_CAPABILITYMASK 0x00000177L")
189 cpp_quote("#define SFGAO_ENCRYPTED 0x00002000L")
190 cpp_quote("#define SFGAO_ISSLOW 0x00004000L")
191 cpp_quote("#define SFGAO_GHOSTED 0x00008000L")
192 cpp_quote("#define SFGAO_LINK 0x00010000L")
193 cpp_quote("#define SFGAO_SHARE 0x00020000L")
194 cpp_quote("#define SFGAO_READONLY 0x00040000L")
195 cpp_quote("#define SFGAO_HIDDEN 0x00080000L")
196 cpp_quote("#define SFGAO_DISPLAYATTRMASK 0x000FC000L")
197 cpp_quote("#define SFGAO_FILESYSANCESTOR 0x10000000L")
198 cpp_quote("#define SFGAO_FOLDER 0x20000000L")
199 cpp_quote("#define SFGAO_FILESYSTEM 0x40000000L")
200 cpp_quote("#define SFGAO_HASSUBFOLDER 0x80000000L")
201 cpp_quote("#define SFGAO_CONTENTSMASK 0x80000000L")
202 cpp_quote("#define SFGAO_VALIDATE 0x01000000L")
203 cpp_quote("#define SFGAO_REMOVABLE 0x02000000L")
204 cpp_quote("#define SFGAO_COMPRESSED 0x04000000L")
205 cpp_quote("#define SFGAO_BROWSABLE 0x08000000L")
206 cpp_quote("#define SFGAO_NONENUMERATED 0x00100000L")
207 cpp_quote("#define SFGAO_NEWCONTENT 0x00200000L")
208 cpp_quote("#define SFGAO_STREAM 0x00400000L")
209 cpp_quote("#define SFGAO_STORAGEANCESTOR 0x00800000L")
210
211 typedef ULONG SFGAOF;
212
213 HRESULT ParseDisplayName(
214 [in] HWND hwndOwner,
215 [in] LPBC pbcReserved,
216 [in, string] LPOLESTR lpszDisplayName,
217 [out] ULONG *pchEaten,
218 [out] PIDLIST_RELATIVE *ppidl,
219 [in, out, unique] ULONG *pdwAttributes);
220
221 HRESULT EnumObjects(
222 [in] HWND hwndOwner,
223 [in] SHCONTF grfFlags,
224 [out] IEnumIDList **ppenumIDList);
225
226 HRESULT BindToObject(
227 [in] PCUIDLIST_RELATIVE pidl,
228 [in] LPBC pbcReserved,
229 [in] REFIID riid,
230 [out, iid_is(riid)] void **ppvOut);
231
232 HRESULT BindToStorage(
233 [in] PCUIDLIST_RELATIVE pidl,
234 [in] LPBC pbcReserved,
235 [in] REFIID riid,
236 [out, iid_is(riid)] void **ppvObj);
237
238 HRESULT CompareIDs(
239 [in] LPARAM lParam,
240 [in] PCUIDLIST_RELATIVE pidl1,
241 [in] PCUIDLIST_RELATIVE pidl2);
242
243 HRESULT CreateViewObject(
244 [in] HWND hwndOwner,
245 [in] REFIID riid,
246 [out, iid_is(riid)] void **ppvOut);
247
248 HRESULT GetAttributesOf(
249 [in] UINT cidl,
250 [in, size_is(cidl)] PCUITEMID_CHILD_ARRAY apidl,
251 [in, out] SFGAOF *rgfInOut);
252
253 HRESULT GetUIObjectOf(
254 [in] HWND hwndOwner,
255 [in] UINT cidl,
256 [in, size_is(cidl)] PCUITEMID_CHILD_ARRAY apidl,
257 [in] REFIID riid,
258 [in, out, unique] UINT *prgfInOut,
259 [out, iid_is(riid)] void **ppvOut);
260
261 HRESULT GetDisplayNameOf(
262 [in] PCUITEMID_CHILD pidl,
263 [in] SHGDNF uFlags,
264 [out] STRRET *lpName);
265
266 HRESULT SetNameOf(
267 [in] HWND hwnd,
268 [in] PCUITEMID_CHILD pidl,
269 [in, string] LPCOLESTR lpszName,
270 [in] SHGDNF uFlags,
271 [out] PITEMID_CHILD *ppidlOut);
272 }
273
274
275 /*****************************************************************************
276 * IEnumExtraSearch interface
277 */
278 [
279 object,
280 uuid(0e700be1-9db6-11d1-a1ce-00c04fd75d13),
281 pointer_default(unique)
282 ]
283 interface IEnumExtraSearch : IUnknown
284 {
285 typedef IEnumExtraSearch *LPENUMEXTRASEARCH;
286
287 typedef struct
288 {
289 GUID guidSearch;
290 WCHAR wszFriendlyName[80];
291 /*
292 *WCHAR wszMenuText[80];
293 *WCHAR wszHelpText[MAX_PATH];
294 */
295 WCHAR wszUrl[2084];
296 /*
297 *WCHAR wszIcon[MAX_PATH+10];
298 *WCHAR wszGreyIcon[MAX_PATH+10];
299 *WCHAR wszClrIcon[MAX_PATH+10];
300 */
301 } EXTRASEARCH, *LPEXTRASEARCH;
302
303 HRESULT Next(
304 [in] ULONG celt,
305 [out, size_is(celt), length_is(*pceltFetched)] EXTRASEARCH *rgelt,
306 [out] ULONG *pceltFetched);
307
308 HRESULT Skip( [in] ULONG celt );
309 HRESULT Reset();
310 HRESULT Clone( [out] IEnumExtraSearch **ppenum );
311 }
312
313
314 /*****************************************************************************
315 * IShellFolder2 interface
316 */
317 [
318 object,
319 uuid(93f2f68c-1d1b-11d3-a30e-00c04f79abd1),
320 pointer_default(unique)
321 ]
322 interface IShellFolder2 : IShellFolder
323 {
324 typedef struct
325 {
326 GUID fmtid;
327 DWORD pid;
328 } SHCOLUMNID, *LPSHCOLUMNID;
329 typedef const SHCOLUMNID *LPCSHCOLUMNID;
330
331 HRESULT GetDefaultSearchGUID( [out] GUID *lpguid );
332 HRESULT EnumSearches( [out] IEnumExtraSearch **ppenum );
333 HRESULT GetDefaultColumn( [in] DWORD dwReserved, [out] ULONG *pSort, [out] ULONG *pDisplay );
334 HRESULT GetDefaultColumnState( [in] UINT iColumn, [out] SHCOLSTATEF *pcsFlags );
335 HRESULT GetDetailsEx( [in] PCUITEMID_CHILD pidl, [in] const SHCOLUMNID *pscid, [out] VARIANT *pv);
336 HRESULT GetDetailsOf( [in] PCUITEMID_CHILD pidl, [in] UINT iColumn, [out] SHELLDETAILS *psd);
337 HRESULT MapColumnToSCID( [in] UINT iColumn, [in] SHCOLUMNID *pscid );
338 }
339
340 /*****************************************************************************
341 * IShellItem interface
342 */
343 [
344 object,
345 uuid(43826d1e-e718-42ee-bc55-a1e261c37bfe),
346 pointer_default(unique)
347 ]
348 interface IShellItem : IUnknown
349 {
350 typedef [v1_enum] enum {
351 SIGDN_NORMALDISPLAY = 0,
352 SIGDN_PARENTRELATIVEPARSING = 0x80018001,
353 SIGDN_DESKTOPABSOLUTEPARSING = 0x80028000,
354 SIGDN_PARENTRELATIVEEDITING = 0x80031001,
355 SIGDN_DESKTOPABSOLUTEEDITING = 0x8004c000,
356 SIGDN_FILESYSPATH = 0x80058000,
357 SIGDN_URL = 0x80068000,
358 SIGDN_PARENTRELATIVEFORADDRESSBAR = 0x8007c001,
359 SIGDN_PARENTRELATIVE = 0x80080001
360 } SIGDN; /* & 0xFFFF => SHGDN */
361
362 [v1_enum] enum _SICHINTF
363 {
364 SICHINT_DISPLAY = 0x00000000,
365 SICHINT_CANONICAL = 0x10000000,
366 SICHINT_TEST_FILESYSPATH_IF_NOT_EQUAL = 0x20000000,
367 SICHINT_ALLFIELDS = 0x80000000
368 };
369 typedef DWORD SICHINTF;
370
371 HRESULT BindToHandler(
372 [in] IBindCtx *pbc,
373 [in] REFGUID rbhid,
374 [in] REFIID riid,
375 [out, iid_is(riid)] void **ppvOut);
376
377 HRESULT GetParent( [out] IShellItem **ppsi );
378
379 HRESULT GetDisplayName(
380 [in] SIGDN sigdnName,
381 [out] LPWSTR *ppszName);
382
383 HRESULT GetAttributes(
384 [in] SFGAOF sfgaoMask,
385 [out] SFGAOF *psfgaoAttribs);
386
387 HRESULT Compare(
388 [in] IShellItem *psi,
389 [in] SICHINTF hint,
390 [out] int *piOrder);
391 }
392
393 /*****************************************************************************
394 * IShellItem2 interface
395 */
396 [
397 object,
398 uuid(7E9FB0D3-919F-4307-AB2E-9B1860310C93),
399 pointer_default(unique)
400 ]
401 interface IShellItem2 : IShellItem
402 {
403 HRESULT GetPropertyStore(
404 [in] GETPROPERTYSTOREFLAGS flags,
405 [in] REFIID riid,
406 [out, iid_is(riid)] void **ppv);
407
408 HRESULT GetPropertyStoreWithCreateObject(
409 [in] GETPROPERTYSTOREFLAGS flags,
410 [in] IUnknown *punkCreateObject,
411 [in] REFIID riid,
412 [out, iid_is(riid)] void **ppv);
413
414 HRESULT GetPropertyStoreForKeys(
415 [in, size_is(cKeys)] const PROPERTYKEY *rgKeys,
416 [in] UINT cKeys,
417 [in] GETPROPERTYSTOREFLAGS flags,
418 [in] REFIID riid,
419 [out, iid_is(riid)] void **ppv);
420
421 HRESULT GetPropertyDescriptionList(
422 [in] REFPROPERTYKEY keyType,
423 [in] REFIID riid,
424 [out, iid_is(riid)] void **ppv);
425
426 HRESULT Update(
427 [in, unique] IBindCtx *pbc);
428
429 HRESULT GetProperty(
430 [in] REFPROPERTYKEY key,
431 [out] PROPVARIANT *ppropvar);
432
433 HRESULT GetCLSID(
434 [in] REFPROPERTYKEY key,
435 [out] CLSID *pclsid);
436
437 HRESULT GetFileTime (
438 [in] REFPROPERTYKEY key,
439 [out] FILETIME *pft);
440
441 HRESULT GetInt32(
442 [in] REFPROPERTYKEY key,
443 [out] int *pi);
444
445 HRESULT GetString(
446 [in] REFPROPERTYKEY key,
447 [out, string] LPWSTR *ppsz);
448
449 HRESULT GetUInt32(
450 [in] REFPROPERTYKEY key,
451 [out] ULONG *pui);
452
453 HRESULT GetUInt64(
454 [in] REFPROPERTYKEY key,
455 [out] ULONGLONG *pull);
456
457 HRESULT GetBool(
458 [in] REFPROPERTYKEY key,
459 [out] BOOL *pf);
460 }
461
462 typedef enum tagNWMF {
463 NWMF_UNLOADING = 0x0001,
464 NWMF_USERINITED = 0x0002,
465 NWMF_FIRST = 0x0004,
466 NWMF_OVERRIDEKEY = 0x0008,
467 NWMF_SHOWHELP = 0x0010,
468 NWMF_HTMLDIALOG = 0x0020,
469 NWMF_FROMDIALOGCHILD = 0x0040,
470 NWMF_USERREQUESTED = 0x0080,
471 NWMF_USERALLOWED = 0x0100
472 } NWMF;
473
474 [
475 uuid(d2bc4c84-3f72-4a52-a604-7bcbf3982cbb),
476 object,
477 pointer_default(unique)
478 ]
479 interface INewWindowManager : IUnknown
480 {
481 HRESULT EvaluateNewWindow(
482 [in, string] LPCWSTR pszUrl,
483 [in, string] LPCWSTR pszName,
484 [in, string] LPCWSTR pszUrlContext,
485 [in, string] LPCWSTR pszFeatures,
486 [in] BOOL fReplace,
487 [in] DWORD dwFlags,
488 [in] DWORD dwUserActionTime);
489 }
490
491 cpp_quote("#define SID_SNewWindowManager IID_INewWindowManager")
492
493 /*****************************************************************************
494 * IEnumShellItems interface
495 */
496 [
497 object,
498 uuid(70629033-E363-4A28-A567-0DB78006E6D7),
499 pointer_default(unique)
500 ]
501 interface IEnumShellItems : IUnknown
502 {
503 [local] HRESULT Next(
504 [in] ULONG celt,
505 [out, size_is(celt), length_is(*pceltFetched)] IShellItem **rgelt,
506 [out] ULONG *pceltFetched);
507
508 [call_as(Next)] HRESULT RemoteNext(
509 [in] ULONG celt,
510 [out, size_is(celt), length_is(*pceltFetched)] IShellItem **rgelt,
511 [out] ULONG *pceltFetched);
512
513 HRESULT Skip(
514 [in] ULONG celt);
515
516 HRESULT Reset();
517
518 HRESULT Clone(
519 [out] IEnumShellItems **ppenum);
520 }
521
522 /*****************************************************************************
523 * IShellItemArray interface
524 */
525 [
526 object,
527 uuid(B63EA76D-1F85-456F-A19C-48159EFA858B),
528 pointer_default(unique)
529 ]
530 interface IShellItemArray : IUnknown
531 {
532 typedef [v1_enum] enum SIATTRIBFLAGS {
533 SIATTRIBFLAGS_AND = 0x0001,
534 SIATTRIBFLAGS_OR = 0x0002,
535 SIATTRIBFLAGS_APPCOMPAT = 0x0003,
536 SIATTRIBFLAGS_MASK = 0x0003,
537 SIATTRIBFLAGS_ALLITEMS = 0x4000
538 } SIATTRIBFLAGS;
539 cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(SIATTRIBFLAGS)")
540
541 HRESULT BindToHandler(
542 [in, unique] IBindCtx *pbc,
543 [in] REFGUID bhid,
544 [in] REFIID riid,
545 [out, iid_is(riid)] void **ppvOut);
546
547 HRESULT GetPropertyStore(
548 [in] GETPROPERTYSTOREFLAGS flags,
549 [in] REFIID riid,
550 [out, iid_is(riid)] void **ppv);
551
552 HRESULT GetPropertyDescriptionList(
553 [in] REFPROPERTYKEY keyType,
554 [in] REFIID riid,
555 [out, iid_is(riid)] void **ppv);
556
557 HRESULT GetAttributes(
558 [in] SIATTRIBFLAGS AttribFlags,
559 [in] SFGAOF sfgaoMask,
560 [out] SFGAOF *psfgaoAttribs);
561
562 HRESULT GetCount(
563 [out] DWORD *pdwNumItems);
564
565 HRESULT GetItemAt(
566 [in] DWORD dwIndex,
567 [out] IShellItem **ppsi);
568
569 HRESULT EnumItems(
570 [out] IEnumShellItems **ppenumShellItems);
571
572 }
573
574 typedef [v1_enum] enum DATAOBJ_GET_ITEM_FLAGS
575 {
576 DOGIF_DEFAULT = 0x0,
577 DOGIF_TRAVERSE_LINK = 0x1,
578 DOGIF_NO_HDROP = 0x2,
579 DOGIF_NO_URL = 0x4,
580 DOGIF_ONLY_IF_ONE = 0x8
581 } DATAOBJ_GET_ITEM_FLAGS;
582 cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(DATAOBJ_GET_ITEM_FLAGS)")
583
584 cpp_quote("HRESULT WINAPI SHGetNameFromIDList(PCIDLIST_ABSOLUTE pidl, SIGDN sigdnName, PWSTR *ppszName);")
585 cpp_quote("HRESULT WINAPI SHCreateItemFromParsingName(PCWSTR pszPath, IBindCtx *pbc, REFIID riid, void **ppv);")
586 cpp_quote("HRESULT WINAPI SHCreateItemFromIDList(PCIDLIST_ABSOLUTE pidl, REFIID riid, void **ppv);")
587 cpp_quote("HRESULT WINAPI SHGetItemFromDataObject(IDataObject *pdtobj, DATAOBJ_GET_ITEM_FLAGS dwFlags, REFIID riid, void **ppv);")
588 cpp_quote("HRESULT WINAPI SHGetIDListFromObject(IUnknown *punk, PIDLIST_ABSOLUTE *ppidl);")
589 cpp_quote("HRESULT WINAPI SHGetItemFromObject(IUnknown *punk, REFIID riid, void **ppv);")
590 cpp_quote("HRESULT WINAPI SHCreateShellItemArray(PCIDLIST_ABSOLUTE pidlParent, IShellFolder* psf, UINT cidl, PCUITEMID_CHILD_ARRAY ppidl, IShellItemArray **ppsiItemArray);")
591 cpp_quote("HRESULT WINAPI SHCreateShellItemArrayFromShellItem(IShellItem *psi, REFIID riid, void **ppv);")
592 cpp_quote("HRESULT WINAPI SHCreateShellItemArrayFromDataObject(IDataObject *pdo, REFIID riid, void **ppv);")
593
594 /*****************************************************************************
595 * IShellItemFilter interface
596 */
597 [
598 object,
599 uuid(2659B475-EEB8-48B7-8F07-B378810F48CF),
600 pointer_default(unique)
601 ]
602 interface IShellItemFilter : IUnknown
603 {
604 HRESULT IncludeItem(
605 [in] IShellItem *psi);
606
607 HRESULT GetEnumFlagsForItem(
608 [in] IShellItem *psi,
609 [out] SHCONTF *pgrfFlags);
610 }
611
612 /*****************************************************************************
613 * FOLDERSETTINGS
614 */
615 typedef char *LPVIEWSETTINGS;
616
617 typedef enum
618 {
619 FWF_AUTOARRANGE = 0x00000001,
620 FWF_ABBREVIATEDNAMES = 0x00000002,
621 FWF_SNAPTOGRID = 0x00000004,
622 FWF_OWNERDATA = 0x00000008,
623 FWF_BESTFITWINDOW = 0x00000010,
624 FWF_DESKTOP = 0x00000020,
625 FWF_SINGLESEL = 0x00000040,
626 FWF_NOSUBFOLDERS = 0x00000080,
627 FWF_TRANSPARENT = 0x00000100,
628 FWF_NOCLIENTEDGE = 0x00000200,
629 FWF_NOSCROLL = 0x00000400,
630 FWF_ALIGNLEFT = 0x00000800,
631 FWF_NOICONS = 0x00001000,
632 FWF_SHOWSELALWAYS = 0x00002000,
633 FWF_NOVISIBLE = 0x00004000,
634 FWF_SINGLECLICKACTIVATE = 0x00008000,
635 FWF_NOWEBVIEW = 0x00010000,
636 FWF_HIDEFILENAMES = 0x00020000,
637 FWF_CHECKSELECT = 0x00040000,
638 FWF_NOENUMREFRESH = 0x00080000,
639 FWF_NOGROUPING = 0x00100000,
640 FWF_FULLROWSELECT = 0x00200000,
641 FWF_NOFILTERS = 0x00400000,
642 FWF_NOCOLUMNHEADER = 0x00800000,
643 FWF_NOHEADERINALLVIEWS = 0x01000000,
644 FWF_EXTENDEDTILES = 0x02000000,
645 FWF_TRICHECKSELECT = 0x04000000,
646 FWF_AUTOCHECKSELECT = 0x08000000,
647 FWF_NOBROWSERVIEWSTATE = 0x10000000,
648 FWF_SUBSETGROUPS = 0x20000000,
649 FWF_USESEARCHFOLDER = 0x40000000,
650 FWF_ALLOWRTLREADING = 0x80000000
651 } FOLDERFLAGS;
652
653 typedef enum
654 {
655 FVM_AUTO =-1,
656 FVM_ICON = 1,
657 FVM_FIRST = FVM_ICON,
658 FVM_SMALLICON = 2,
659 FVM_LIST = 3,
660 FVM_DETAILS = 4,
661 FVM_THUMBNAIL = 5,
662 FVM_TILE = 6,
663 FVM_THUMBSTRIP = 7,
664 FVM_CONTENT = 8,
665 FVM_LAST = FVM_CONTENT
666 } FOLDERVIEWMODE;
667
668 typedef struct
669 {
670 UINT ViewMode;
671 UINT fFlags;
672 } FOLDERSETTINGS, *PFOLDERSETTINGS, *LPFOLDERSETTINGS;
673 typedef const FOLDERSETTINGS *LPCFOLDERSETTINGS;
674
675 /*****************************************************************************
676 * IShellIcon interface
677 */
678 [
679 uuid(000214e5-0000-0000-c000-000000000046),
680 object,
681 pointer_default(unique)
682 ]
683 interface IShellIcon : IUnknown
684 {
685 HRESULT GetIconOf(
686 [in] PCUITEMID_CHILD pidl,
687 [in] UINT flags,
688 [out] int *pIconIndex);
689 }
690
691 /*****************************************************************************
692 * IShellView interface
693 */
694 interface IShellBrowser; /* forward declaration */
695 [
696 object,
697 uuid(000214e3-0000-0000-c000-000000000046),
698 pointer_default(unique)
699 ]
700 interface IShellView : IOleWindow
701 {
702 typedef IShellView *LPSHELLVIEW;
703
704 cpp_quote("#define SVSI_DESELECT 0x00000000")
705 cpp_quote("#define SVSI_SELECT 0x00000001")
706 cpp_quote("#define SVSI_EDIT 0x00000003")
707 cpp_quote("#define SVSI_DESELECTOTHERS 0x00000004")
708 cpp_quote("#define SVSI_ENSUREVISIBLE 0x00000008")
709 cpp_quote("#define SVSI_FOCUSED 0x00000010")
710 cpp_quote("#define SVSI_TRANSLATEPT 0x00000020")
711 cpp_quote("#define SVSI_SELECTIONMARK 0x00000040")
712 cpp_quote("#define SVSI_POSITIONITEM 0x00000080")
713 cpp_quote("#define SVSI_CHECK 0x00000100")
714 cpp_quote("#define SVSI_NOSTATECHANGE 0x80000000")
715
716 typedef UINT SVSIF;
717
718 typedef enum
719 {
720 SVGIO_BACKGROUND = 0x00000000,
721 SVGIO_SELECTION = 0x00000001,
722 SVGIO_ALLVIEW = 0x00000002,
723 SVGIO_CHECKED = 0x00000003,
724 SVGIO_TYPE_MASK = 0x0000000f,
725 SVGIO_FLAG_VIEWORDER = 0x80000000,
726 } SVGIO;
727
728 typedef enum
729 {
730 SVUIA_DEACTIVATE = 0,
731 SVUIA_ACTIVATE_NOFOCUS = 1,
732 SVUIA_ACTIVATE_FOCUS = 2,
733 SVUIA_INPLACEACTIVATE = 3
734 } SVUIA_STATUS;
735
736 HRESULT TranslateAccelerator( [in] MSG *pmsg );
737 HRESULT EnableModeless( [in] BOOL fEnable );
738 HRESULT UIActivate( [in] UINT uState );
739 HRESULT Refresh();
740 HRESULT CreateViewWindow(
741 [in] IShellView *psvPrevious,
742 [in] LPCFOLDERSETTINGS lpfs,
743 [in] IShellBrowser *psb,
744 [out] RECT *prcView,
745 [out] HWND *phWnd);
746
747 HRESULT DestroyViewWindow();
748 HRESULT GetCurrentInfo( [out] LPFOLDERSETTINGS lpfs );
749
750 [local] HRESULT AddPropertySheetPages(
751 [in] DWORD dwReserved,
752 [in] LPFNSVADDPROPSHEETPAGE pfn,
753 [in] LPARAM lparam);
754
755 HRESULT SaveViewState();
756 HRESULT SelectItem(
757 [in] LPCITEMIDLIST pidlItem,
758 [in] SVSIF uFlags);
759 HRESULT GetItemObject(
760 [in] UINT uItem,
761 [in] REFIID riid,
762 [out, iid_is(riid)] void **ppv);
763 }
764
765 [
766 object,
767 uuid(88e39e80-3578-11cf-ae69-08002b2e1262),
768 pointer_default(unique)
769 ]
770 interface IShellView2 : IShellView
771 {
772 typedef GUID SHELLVIEWID;
773 cpp_quote("#include <pshpack8.h>")
774 typedef struct _SV2CVW2_PARAMS
775 {
776 DWORD cbSize;
777 IShellView *psvPrev;
778 LPCFOLDERSETTINGS pfs;
779 IShellBrowser *psbOwner;
780 RECT *prcView;
781 SHELLVIEWID const *pvid;
782 HWND hwndView;
783 } SV2CVW2_PARAMS, *LPSV2CVW2_PARAMS;
784 cpp_quote("#include <poppack.h>")
785
786 HRESULT GetView(
787 [in, out] SHELLVIEWID *view_guid,
788 [in] ULONG view_type
789 );
790 HRESULT CreateViewWindow2(
791 [in] LPSV2CVW2_PARAMS view_params
792 );
793 HRESULT HandleRename(
794 [in] LPCITEMIDLIST new_pidl
795 );
796 HRESULT SelectAndPositionItem(
797 [in] LPCITEMIDLIST item,
798 [in] UINT flags,
799 [in] POINT *point
800 );
801 }
802
803 /*****************************************************************************
804 * IFolderView interface
805 */
806 [
807 uuid(cde725b0-ccc9-4519-917e-325d72fab4ce),
808 object,
809 pointer_default(unique)
810 ]
811 interface IFolderView : IUnknown
812 {
813 HRESULT GetCurrentViewMode( [out] UINT *mode );
814 HRESULT SetCurrentViewMode( [in] UINT mode );
815 HRESULT GetFolder( [in] REFIID riid, [out, iid_is(riid)] void **ppv );
816 HRESULT Item(
817 [in] int index,
818 [out] PITEMID_CHILD *ppidl
819 );
820 HRESULT ItemCount(
821 [in] UINT flags,
822 [out] int *items
823 );
824 HRESULT Items(
825 [in] UINT flags,
826 [in] REFIID riid,
827 [out, iid_is(riid)] void **ppv
828 );
829 HRESULT GetSelectionMarkedItem( [out] int *item );
830 HRESULT GetFocusedItem( [out] int *item );
831 HRESULT GetItemPosition(
832 [in] PCUITEMID_CHILD pidl,
833 [out] POINT* ppt
834 );
835 HRESULT GetSpacing( [in, out, unique] POINT* pt );
836 HRESULT GetDefaultSpacing( [out] POINT* pt );
837 HRESULT GetAutoArrange();
838 HRESULT SelectItem(
839 [in] int item,
840 [in] DWORD flags
841 );
842 HRESULT SelectAndPositionItems(
843 [in] UINT cidl,
844 [in, size_is(cidl)] PCUITEMID_CHILD_ARRAY apidl,
845 [in, unique, size_is(cidl)] POINT* apt,
846 [in] DWORD flags
847 );
848 }
849
850 [v1_enum] enum tagSORTDIRECTION
851 {
852 SORT_DESCENDING = -1,
853 SORT_ASCENDING = 1
854 };
855 typedef int SORTDIRECTION;
856
857 typedef struct SORTCOLUMN
858 {
859 PROPERTYKEY propkey;
860 SORTDIRECTION direction;
861 } SORTCOLUMN;
862
863 typedef [v1_enum] enum FVTEXTTYPE
864 {
865 FVST_EMPTYTEXT = 0
866 } FVTEXTTYPE;
867
868 [
869 uuid(1af3a467-214f-4298-908e-06b03e0b39f9),
870 object,
871 pointer_default(unique)
872 ]
873 interface IFolderView2 : IFolderView
874 {
875 HRESULT SetGroupBy(
876 [in] REFPROPERTYKEY key,
877 [in] BOOL ascending);
878
879 [local]
880 HRESULT GetGroupBy(
881 [out] PROPERTYKEY *pkey,
882 [out] BOOL *ascending);
883
884 [call_as(GetGroupBy)]
885 HRESULT RemoteGetGroupBy(
886 [out] PROPERTYKEY *pkey,
887 [out] BOOL *ascending);
888
889 HRESULT SetViewProperty(
890 [in] PCUITEMID_CHILD pidl,
891 [in] REFPROPERTYKEY propkey,
892 [in] REFPROPVARIANT propvar);
893
894 HRESULT GetViewProperty(
895 [in] PCUITEMID_CHILD pidl,
896 [in] REFPROPERTYKEY propkey,
897 [out] PROPVARIANT *propvar);
898
899 HRESULT SetTileViewProperties(
900 [in] PCUITEMID_CHILD pidl,
901 [in, string] LPCWSTR prop_list);
902
903 HRESULT SetExtendedTileViewProperties(
904 [in] PCUITEMID_CHILD pidl,
905 [in, string] LPCWSTR prop_list);
906
907 HRESULT SetText(
908 [in] FVTEXTTYPE type,
909 [in] LPCWSTR text);
910
911 HRESULT SetCurrentFolderFlags(
912 [in] DWORD mask,
913 [in] DWORD flags);
914
915 HRESULT GetCurrentFolderFlags([out] DWORD *flags);
916
917 HRESULT GetSortColumnCount([out] int *columns);
918
919 HRESULT SetSortColumns(
920 [in, size_is(count)] const SORTCOLUMN *columns,
921 [in] int count);
922
923 HRESULT GetSortColumns(
924 [out, size_is(count)] SORTCOLUMN *columns,
925 [in] int count);
926
927 HRESULT GetItem(
928 [in] int ittem,
929 [in] REFIID riid,
930 [out, iid_is(riid)] void **ppv);
931
932 HRESULT GetVisibleItem(
933 [in] int start,
934 [in] BOOL previous,
935 [out] int *item);
936
937 HRESULT GetSelectedItem(
938 [in] int start,
939 [out] int *item);
940
941 HRESULT GetSelection(
942 [in] BOOL none_implies_folder,
943 [out] IShellItemArray **array);
944
945 HRESULT GetSelectionState(
946 [in] PCUITEMID_CHILD pidl,
947 [out] DWORD *flags);
948
949 HRESULT InvokeVerbOnSelection([in, unique, string] LPCSTR verb);
950
951 HRESULT SetViewModeAndIconSize(
952 [in] FOLDERVIEWMODE mode,
953 [in] int size);
954
955 HRESULT GetViewModeAndIconSize(
956 [out] FOLDERVIEWMODE *mode,
957 [out] int *size);
958
959 HRESULT SetGroupSubsetCount([in] UINT visible_rows);
960
961 HRESULT GetGroupSubsetCount([out] UINT *visible_rows);
962
963 HRESULT SetRedraw([in] BOOL redraw);
964
965 HRESULT IsMoveInSameFolder();
966
967 HRESULT DoRename();
968 }
969
970 /*****************************************************************************
971 * IShellBrowser interface
972 */
973 [
974 object,
975 uuid(000214e2-0000-0000-c000-000000000046),
976 pointer_default(unique)
977 ]
978 interface IShellBrowser : IOleWindow
979 {
980 typedef IShellBrowser *LPSHELLBROWSER;
981
982 cpp_quote("#define SBSP_DEFBROWSER 0x00000000")
983 cpp_quote("#define SBSP_SAMEBROWSER 0x00000001")
984 cpp_quote("#define SBSP_NEWBROWSER 0x00000002")
985 cpp_quote("#define SBSP_DEFMODE 0x00000000")
986 cpp_quote("#define SBSP_OPENMODE 0x00000010")
987 cpp_quote("#define SBSP_EXPLOREMODE 0x00000020")
988 cpp_quote("#define SBSP_HELPMODE 0x00000040")
989 cpp_quote("#define SBSP_NOTRANSFERHIST 0x00000080")
990 cpp_quote("#define SBSP_ABSOLUTE 0x00000000")
991 cpp_quote("#define SBSP_RELATIVE 0x00001000")
992 cpp_quote("#define SBSP_PARENT 0x00002000")
993 cpp_quote("#define SBSP_NAVIGATEBACK 0x00004000")
994 cpp_quote("#define SBSP_NAVIGATEFORWARD 0x00008000")
995 cpp_quote("#define SBSP_ALLOW_AUTONAVIGATE 0x00010000")
996 cpp_quote("#define SBSP_KEEPSAMETEMPLATE 0x00020000")
997 cpp_quote("#define SBSP_KEEPWORDWHEELTEXT 0x00040000")
998 cpp_quote("#define SBSP_ACTIVATE_NOFOCUS 0x00080000")
999 cpp_quote("#define SBSP_CREATENOHISTORY 0x00100000")
1000 cpp_quote("#define SBSP_PLAYNOSOUND 0x00200000")
1001 cpp_quote("#define SBSP_CALLERUNTURUSTED 0x00800000")
1002 cpp_quote("#define SBSP_TRUSTFIRSTDOWNLOAD 0x01000000")
1003 cpp_quote("#define SBSP_UNTRUSTEDFORDOWNLOAD 0x02000000")
1004 cpp_quote("#define SBSP_NOAUTOSELECT 0x04000000")
1005 cpp_quote("#define SBSP_WRITENOHISTORY 0x08000000")
1006 cpp_quote("#define SBSP_TRUSTEDFORACTIVEX 0x10000000")
1007 cpp_quote("#define SBSP_FEEDNAVIGATION 0x20000000")
1008 cpp_quote("#define SBSP_REDIRECT 0x40000000")
1009 cpp_quote("#define SBSP_INITIATEDBYHLINKFRAME 0x80000000")
1010
1011 cpp_quote("#define FCW_STATUS 0x0001")
1012 cpp_quote("#define FCW_TOOLBAR 0x0002")
1013 cpp_quote("#define FCW_TREE 0x0003")
1014 cpp_quote("#define FCW_INTERNETBAR 0x0006")
1015 cpp_quote("#define FCW_PROGRESS 0x0008")
1016
1017 cpp_quote("#define FCT_MERGE 0x0001")
1018 cpp_quote("#define FCT_CONFIGABLE 0x0002")
1019 cpp_quote("#define FCT_ADDTOEND 0x0004")
1020
1021 cpp_quote("#if 0")
1022 typedef LPARAM LPTBBUTTONSB;
1023 cpp_quote("#else")
1024 cpp_quote("#include <commctrl.h>")
1025 cpp_quote("typedef LPTBBUTTON LPTBBUTTONSB;")
1026 cpp_quote("#endif")
1027
1028 HRESULT InsertMenusSB(
1029 [in] HMENU hmenuShared,
1030 [in, out] LPOLEMENUGROUPWIDTHS lpMenuWidths);
1031
1032 HRESULT SetMenuSB(
1033 [in] HMENU hmenuShared,
1034 [in] HOLEMENU holemenuReserved,
1035 [in] HWND hwndActiveObject);
1036
1037 HRESULT RemoveMenusSB( [in] HMENU hmenuShared );
1038 HRESULT SetStatusTextSB( [in, unique] LPCOLESTR pszStatusText );
1039 HRESULT EnableModelessSB( [in] BOOL fEnable );
1040 HRESULT TranslateAcceleratorSB( [in] MSG *pmsg, [in] WORD wID );
1041
1042 HRESULT BrowseObject(
1043 [in] LPCITEMIDLIST pidl,
1044 [in] UINT wFlags);
1045
1046 HRESULT GetViewStateStream(
1047 [in] DWORD grfMode,
1048 [out] IStream **ppStrm);
1049
1050 HRESULT GetControlWindow(
1051 [in] UINT id,
1052 [out] HWND *phwnd);
1053
1054 [local] HRESULT SendControlMsg(
1055 [in] UINT id,
1056 [in] UINT uMsg,
1057 [in] WPARAM wParam,
1058 [in] LPARAM lParam,
1059 [in] LRESULT *pret);
1060
1061 HRESULT QueryActiveShellView( [out] IShellView **ppshv );
1062 HRESULT OnViewWindowActive( [in] IShellView *pshv );
1063
1064 [local]
1065 HRESULT SetToolbarItems(
1066 [in] LPTBBUTTONSB lpButtons,
1067 [in] UINT nButtons,
1068 [in] UINT uFlags);
1069 }
1070
1071
1072 /*****************************************************************************
1073 * IShellLinkA interface
1074 */
1075 [
1076 object,
1077 uuid(000214ee-0000-0000-c000-000000000046),
1078 pointer_default(unique)
1079 ]
1080 interface IShellLinkA : IUnknown
1081 {
1082 typedef enum
1083 {
1084 SLR_NO_UI = 0x0001,
1085 SLR_ANY_MATCH = 0x0002,
1086 SLR_UPDATE = 0x0004,
1087 SLR_NOUPDATE = 0x0008,
1088 SLR_NOSEARCH = 0x0010,
1089 SLR_NOTRACK = 0x0020,
1090 SLR_NOLINKINFO = 0x0040,
1091 SLR_INVOKE_MSI = 0x0080,
1092 SLR_NO_UI_WITH_MSG_PUMP = 0x0101,
1093 } SLR_FLAGS;
1094
1095 typedef enum
1096 {
1097 SLGP_SHORTPATH = 0x0001,
1098 SLGP_UNCPRIORITY = 0x0002,
1099 SLGP_RAWPATH = 0x0004,
1100 } SLGP_FLAGS;
1101
1102 HRESULT GetPath(
1103 [out, size_is(cch)] LPSTR pszFile,
1104 [in] int cch,
1105 [in, out, unique] WIN32_FIND_DATAA *pfd,
1106 [in] DWORD fFlags);
1107
1108 HRESULT GetIDList( [out] LPITEMIDLIST * ppidl );
1109
1110 HRESULT SetIDList( [in] LPCITEMIDLIST pidl );
1111
1112 HRESULT GetDescription(
1113 [out, size_is(cch)] LPSTR pszName,
1114 [in] int cch);
1115
1116 HRESULT SetDescription( [in] LPCSTR pszName );
1117
1118 HRESULT GetWorkingDirectory(
1119 [out, size_is(cch)] LPSTR pszDir,
1120 [in] int cch);
1121
1122 HRESULT SetWorkingDirectory( [in] LPCSTR pszDir );
1123
1124 HRESULT GetArguments(
1125 [out, size_is(cch)] LPSTR pszArgs,
1126 [in] int cch);
1127
1128 HRESULT SetArguments( [in] LPCSTR pszArgs );
1129
1130 HRESULT GetHotkey( [out] WORD *pwHotkey );
1131
1132 HRESULT SetHotkey( [in] WORD wHotkey );
1133
1134 HRESULT GetShowCmd( [out] int *piShowCmd );
1135
1136 HRESULT SetShowCmd( [in] int iShowCmd );
1137
1138 HRESULT GetIconLocation(
1139 [out, size_is(cch)] LPSTR pszIconPath,
1140 [in] int cch,
1141 [out] int *piIcon);
1142
1143 HRESULT SetIconLocation(
1144 [in] LPCSTR pszIconPath,
1145 [in] int iIcon);
1146
1147 HRESULT SetRelativePath(
1148 [in] LPCSTR pszPathRel,
1149 [in] DWORD dwReserved);
1150
1151 HRESULT Resolve(
1152 [in] HWND hwnd,
1153 [in] DWORD fFlags);
1154
1155 HRESULT SetPath( [in] LPCSTR pszFile );
1156 }
1157
1158
1159 /*****************************************************************************
1160 * IShellLinkW interface
1161 */
1162 [
1163 object,
1164 uuid(000214f9-0000-0000-c000-000000000046),
1165 pointer_default(unique)
1166 ]
1167 interface IShellLinkW : IUnknown
1168 {
1169 HRESULT GetPath(
1170 [out, size_is(cch)] LPWSTR pszFile,
1171 [in] int cch,
1172 [in, out] WIN32_FIND_DATAW *pfd,
1173 [in] DWORD fFlags);
1174
1175 HRESULT GetIDList( [out] LPITEMIDLIST * ppidl );
1176
1177 HRESULT SetIDList( [in] LPCITEMIDLIST pidl );
1178
1179 HRESULT GetDescription(
1180 [out, size_is(cch)] LPWSTR pszName,
1181 [in] int cch);
1182
1183 HRESULT SetDescription( [in] LPCWSTR pszName );
1184
1185 HRESULT GetWorkingDirectory(
1186 [out, size_is(cch)] LPWSTR pszDir,
1187 [in] int cch);
1188
1189 HRESULT SetWorkingDirectory( [in] LPCWSTR pszDir );
1190
1191 HRESULT GetArguments(
1192 [out, size_is(cch)] LPWSTR pszArgs,
1193 [in] int cch);
1194
1195 HRESULT SetArguments( [in] LPCWSTR pszArgs );
1196
1197 HRESULT GetHotkey( [out] WORD *pwHotkey );
1198
1199 HRESULT SetHotkey( [in] WORD wHotkey );
1200
1201 HRESULT GetShowCmd( [out] int *piShowCmd );
1202
1203 HRESULT SetShowCmd( [in] int iShowCmd );
1204
1205 HRESULT GetIconLocation(
1206 [out, size_is(cch)] LPWSTR pszIconPath,
1207 [in] int cch,
1208 [out] int *piIcon);
1209
1210 HRESULT SetIconLocation(
1211 [in] LPCWSTR pszIconPath,
1212 [in] int iIcon);
1213
1214 HRESULT SetRelativePath(
1215 [in] LPCWSTR pszPathRel,
1216 [in] DWORD dwReserved);
1217
1218 HRESULT Resolve(
1219 [in] HWND hwnd,
1220 [in] DWORD fFlags);
1221
1222 HRESULT SetPath( [in] LPCWSTR pszFile );
1223 }
1224
1225 cpp_quote("#define IShellLink WINELIB_NAME_AW(IShellLink)")
1226
1227
1228 /*****************************************************************************
1229 * IShellExtInit interface
1230 */
1231 [
1232 object,
1233 uuid(000214e8-0000-0000-c000-000000000046),
1234 pointer_default(unique),
1235 local
1236 ]
1237 interface IShellExtInit : IUnknown
1238 {
1239 typedef IShellExtInit *LPSHELLEXTINIT;
1240
1241 HRESULT Initialize(
1242 [in] LPCITEMIDLIST pidlFolder,
1243 [in] IDataObject *pdtobj,
1244 [in] HKEY hkeyProgID);
1245 }
1246
1247
1248 /*******************************************************************************/
1249 /* Note: the following interfaces are not in shobjidl.idl under Windows, they */
1250 /* are declared directly in shlobj.h. It hopefully won't break anything to put */
1251 /* them here anyway. */
1252 /*******************************************************************************/
1253
1254 #ifndef MAX_PATH
1255 #define MAX_PATH 260
1256 #endif
1257
1258
1259 /*****************************************************************************
1260 * IPersistFolder3 interface
1261 */
1262 [
1263 object,
1264 uuid(cef04fdf-fe72-11d2-87a5-00c04f6837cf),
1265 pointer_default(unique)
1266 ]
1267 interface IPersistFolder3 : IPersistFolder2
1268 {
1269 typedef struct
1270 {
1271 LPITEMIDLIST pidlTargetFolder;
1272 WCHAR szTargetParsingName[MAX_PATH];
1273 WCHAR szNetworkProvider[MAX_PATH];
1274 DWORD dwAttributes;
1275 int csidl;
1276 } PERSIST_FOLDER_TARGET_INFO;
1277
1278 HRESULT InitializeEx(
1279 [in] IBindCtx *pbc,
1280 [in] LPCITEMIDLIST pidlRoot,
1281 [in] const PERSIST_FOLDER_TARGET_INFO *ppfti);
1282
1283 HRESULT GetFolderTargetInfo( [out] PERSIST_FOLDER_TARGET_INFO *ppfti );
1284 }
1285
1286
1287 /*****************************************************************************
1288 * IExtractIconA interface
1289 */
1290 [
1291 object,
1292 uuid(000214eb-0000-0000-c000-000000000046),
1293 pointer_default(unique),
1294 local
1295 ]
1296 interface IExtractIconA : IUnknown
1297 {
1298 cpp_quote("#define GIL_OPENICON 0x0001")
1299 cpp_quote("#define GIL_FORSHELL 0x0002")
1300 cpp_quote("#define GIL_ASYNC 0x0020")
1301 cpp_quote("#define GIL_DEFAULTICON 0x0040")
1302 cpp_quote("#define GIL_FORSHORTCUT 0x0080")
1303
1304 cpp_quote("#define GIL_SIMULATEDOC 0x0001")
1305 cpp_quote("#define GIL_PERINSTANCE 0x0002")
1306 cpp_quote("#define GIL_PERCLASS 0x0004")
1307 cpp_quote("#define GIL_NOTFILENAME 0x0008")
1308 cpp_quote("#define GIL_DONTCACHE 0x0010")
1309
1310 typedef IExtractIconA *LPEXTRACTICONA;
1311
1312 HRESULT GetIconLocation(
1313 [in] UINT uFlags,
1314 [out, size_is(cchMax)] LPSTR szIconFile,
1315 [in] UINT cchMax,
1316 [out] INT *piIndex,
1317 [out] UINT *pwFlags);
1318
1319 HRESULT Extract(
1320 [in] LPCSTR pszFile,
1321 [in] UINT nIconIndex,
1322 [out] HICON *phiconLarge,
1323 [out] HICON *phiconSmall,
1324 [in] UINT nIconSize );
1325 }
1326
1327
1328 /*****************************************************************************
1329 * IExtractIconW interface
1330 */
1331 [
1332 object,
1333 uuid(000214fa-0000-0000-c000-000000000046),
1334 pointer_default(unique),
1335 local
1336 ]
1337 interface IExtractIconW : IUnknown
1338 {
1339 typedef IExtractIconW *LPEXTRACTICONW;
1340
1341 HRESULT GetIconLocation(
1342 [in] UINT uFlags,
1343 [out, size_is(cchMax)] LPWSTR szIconFile,
1344 [in] UINT cchMax,
1345 [out] INT *piIndex,
1346 [out] UINT *pwFlags);
1347
1348 HRESULT Extract(
1349 [in] LPCWSTR pszFile,
1350 [in] UINT nIconIndex,
1351 [out] HICON *phiconLarge,
1352 [out] HICON *phiconSmall,
1353 [in] UINT nIconSize );
1354 }
1355
1356 cpp_quote("#define LPEXTRACTICON WINELIB_NAME_AW(LPEXTRACTICON)")
1357 cpp_quote("#define IExtractIcon WINELIB_NAME_AW(IExtractIcon)")
1358
1359
1360 /*****************************************************************************
1361 * ICommDlgBrowser interface
1362 */
1363 [
1364 object,
1365 uuid(000214f1-0000-0000-c000-000000000046),
1366 pointer_default(unique)
1367 ]
1368 interface ICommDlgBrowser : IUnknown
1369 {
1370 cpp_quote("#define CDBOSC_SETFOCUS 0x00000000")
1371 cpp_quote("#define CDBOSC_KILLFOCUS 0x00000001")
1372 cpp_quote("#define CDBOSC_SELCHANGE 0x00000002")
1373 cpp_quote("#define CDBOSC_RENAME 0x00000003")
1374 cpp_quote("#define CDBOSC_STATECHANGE 0x00000004")
1375
1376 typedef ICommDlgBrowser *LPCOMMDLGBROWSER;
1377
1378 HRESULT OnDefaultCommand( [in] IShellView *shv );
1379 HRESULT OnStateChange( [in] IShellView *shv, [in] ULONG uChange );
1380 HRESULT IncludeObject( [in] IShellView *shv, [in] LPCITEMIDLIST pidl );
1381 }
1382
1383
1384 /*****************************************************************************
1385 * ICommDlgBrowser2 interface
1386 */
1387 [
1388 object,
1389 uuid(10339516-2894-11D2-9039-00C04F8EEB3E),
1390 pointer_default(unique)
1391 ]
1392 interface ICommDlgBrowser2 : ICommDlgBrowser
1393 {
1394
1395 HRESULT Notify(
1396 [in] IShellView *ppshv,
1397 [in] DWORD dwNotifyType);
1398
1399 HRESULT GetDefaultMenuText(
1400 [in] IShellView *ppshv,
1401 [out, string, size_is(cchMax)] LPWSTR pszText,
1402 [in] int cchMax);
1403
1404 HRESULT GetViewFlags(
1405 [out] DWORD *pdwFlags);
1406 }
1407
1408
1409 /*****************************************************************************
1410 * ICommDlgBrowser3 interface
1411 */
1412 [
1413 object,
1414 uuid(C8AD25A1-3294-41EE-8165-71174BD01C57),
1415 pointer_default(unique)
1416 ]
1417 interface ICommDlgBrowser3 : ICommDlgBrowser2
1418 {
1419
1420 HRESULT OnColumnClicked(
1421 [in] IShellView *ppshv,
1422 [in] int iColumn);
1423
1424 HRESULT GetCurrentFilter(
1425 [out, string, size_is(cchFileSpec)] LPWSTR pszFileSpec,
1426 [in] int cchFileSpec);
1427
1428 HRESULT OnPreviewCreated(
1429 [in] IShellView *ppshv);
1430 }
1431
1432 /*****************************************************************************
1433 * IDockingWindow interface
1434 */
1435 [
1436 object,
1437 uuid(012dd920-7b26-11d0-8ca9-00a0c92dbfe8)
1438 ]
1439 interface IDockingWindow : IOleWindow
1440 {
1441 HRESULT ShowDW(
1442 [in] BOOL fShow);
1443
1444 HRESULT CloseDW(
1445 [in] DWORD dwReserved);
1446
1447 HRESULT ResizeBorderDW(
1448 [in] LPCRECT prcBorder,
1449 [in] IUnknown *punkToolbarSite,
1450 [in] BOOL fReserved);
1451 };
1452
1453
1454 /*****************************************************************************
1455 * IDockingWindowFrame interface
1456 */
1457 [
1458 object,
1459 uuid(47d2657a-7b27-11d0-8ca9-00a0c92dbfe8),
1460 pointer_default(unique),
1461 local
1462 ]
1463 interface IDockingWindowFrame : IOleWindow
1464 {
1465 cpp_quote("#define DWFRF_NORMAL 0x0000")
1466 cpp_quote("#define DWFRF_DELETECONFIGDATA 0x0001")
1467 cpp_quote("#define DWFAF_HIDDEN 0x0001")
1468
1469 HRESULT AddToolbar(
1470 [in] IUnknown *punkSrc,
1471 [in] LPCWSTR pwszItem,
1472 [in] DWORD dwAddFlags);
1473
1474 HRESULT RemoveToolbar(
1475 [in] IUnknown *punkSrc,
1476 [in] DWORD dwRemoveFlags);
1477
1478 HRESULT FindToolbar(
1479 [in] LPCWSTR pwszItem,
1480 [in] REFIID riid,
1481 [out] LPVOID *ppvObj);
1482 }
1483
1484
1485 /*****************************************************************************
1486 * IDragSourceHelper interface
1487 */
1488 [
1489 object,
1490 uuid(de5bf786-477a-11d2-839d-00c04fd918d0),
1491 pointer_default(unique),
1492 local
1493 ]
1494 interface IDragSourceHelper : IUnknown
1495 {
1496 typedef struct
1497 {
1498 SIZE sizeDragImage;
1499 POINT ptOffset;
1500 HBITMAP hbmpDragImage;
1501 COLORREF crColorKey;
1502 } SHDRAGIMAGE, *LPSHDRAGIMAGE;
1503
1504 HRESULT InitializeFromBitmap(
1505 [in] LPSHDRAGIMAGE pshdi,
1506 [in] IDataObject *pDataObject);
1507
1508 HRESULT InitializeFromWindow(
1509 [in] HWND hwnd,
1510 [in] POINT *ppt,
1511 [in] IDataObject *pDataObject);
1512 }
1513
1514
1515 /*****************************************************************************
1516 * IDropTargetHelper interface
1517 */
1518 [
1519 object,
1520 uuid(4657278b-411b-11d2-839a-00c04fd918d0),
1521 pointer_default(unique),
1522 local
1523 ]
1524 interface IDropTargetHelper : IUnknown
1525 {
1526 HRESULT DragEnter(
1527 [in] HWND hwndTarget,
1528 [in] IDataObject *pDataObject,
1529 [in] POINT *ppt,
1530 [in] DWORD dwEffect);
1531
1532 HRESULT DragLeave();
1533
1534 HRESULT DragOver(
1535 [in] POINT *ppt,
1536 [in] DWORD dwEffect);
1537
1538 HRESULT Drop(
1539 [in] IDataObject *pDataObject,
1540 [in] POINT *ppt,
1541 [in] DWORD dwEffect);
1542
1543 HRESULT Show( [in] BOOL fShow );
1544 }
1545
1546
1547 /*****************************************************************************
1548 * IContextMenu interface
1549 */
1550 [
1551 object,
1552 uuid(000214e4-0000-0000-c000-000000000046),
1553 pointer_default(unique),
1554 local
1555 ]
1556 interface IContextMenu : IUnknown
1557 {
1558 cpp_quote("#define CMF_NORMAL 0x00000000")
1559 cpp_quote("#define CMF_DEFAULTONLY 0x00000001")
1560 cpp_quote("#define CMF_VERBSONLY 0x00000002")
1561 cpp_quote("#define CMF_EXPLORE 0x00000004")
1562 cpp_quote("#define CMF_NOVERBS 0x00000008")
1563 cpp_quote("#define CMF_CANRENAME 0x00000010")
1564 cpp_quote("#define CMF_NODEFAULT 0x00000020")
1565 cpp_quote("#define CMF_INCLUDESTATIC 0x00000040")
1566 cpp_quote("#define CMF_EXTENDEDVERBS 0x00000100")
1567 cpp_quote("#define CMF_RESERVED 0xffff0000")
1568
1569 cpp_quote("#define GCS_VERBA 0x00000000")
1570 cpp_quote("#define GCS_HELPTEXTA 0x00000001")
1571 cpp_quote("#define GCS_VALIDATEA 0x00000002")
1572 cpp_quote("#define GCS_VERBW 0x00000004")
1573 cpp_quote("#define GCS_HELPTEXTW 0x00000005")
1574 cpp_quote("#define GCS_VALIDATEW 0x00000006")
1575 cpp_quote("#define GCS_UNICODE 0x00000004")
1576 cpp_quote("#define GCS_VERB WINELIB_NAME_AW(GCS_VERB)")
1577 cpp_quote("#define GCS_HELPTEXT WINELIB_NAME_AW(GCS_HELPTEXT)")
1578 cpp_quote("#define GCS_VALIDATE WINELIB_NAME_AW(GCS_VALIDATE)")
1579
1580 cpp_quote("#define CMDSTR_NEWFOLDERA \"NewFolder\"")
1581 cpp_quote("#define CMDSTR_VIEWLISTA \"ViewList\"")
1582 cpp_quote("#define CMDSTR_VIEWDETAILSA \"ViewDetails\"")
1583 cpp_quote("#if defined(__GNUC__)")
1584 cpp_quote("# define CMDSTR_NEWFOLDERW (const WCHAR []){ 'N','e','w','F','o','l','d','e','r',0 }")
1585 cpp_quote("# define CMDSTR_VIEWLISTW (const WCHAR []){ 'V','i','e','w','L','i','s','t',0 }")
1586 cpp_quote("# define CMDSTR_VIEWDETAILSW (const WCHAR []){ 'V','i','e','w','D','e','t','a','i','l','s',0 }")
1587 cpp_quote("#elif defined(_MSC_VER)")
1588 cpp_quote("# define CMDSTR_NEWFOLDERW L\"NewFolder\"")
1589 cpp_quote("# define CMDSTR_VIEWLISTW L\"ViewList\"")
1590 cpp_quote("# define CMDSTR_VIEWDETAILSW L\"ViewDetails\"")
1591 cpp_quote("#else")
1592 cpp_quote("static const WCHAR CMDSTR_NEWFOLDERW[] = {'N','e','w','F','o','l','d','e','r',0};")
1593 cpp_quote("static const WCHAR CMDSTR_VIEWLISTW [] = {'V','i','e','w','L','i','s','t',0};")
1594 cpp_quote("static const WCHAR CMDSTR_VIEWDETAILSW[] = {'V','i','e','w','D','e','t','a','i','l','s',0};")
1595 cpp_quote("#endif")
1596 cpp_quote("#define CMDSTR_NEWFOLDER WINELIB_NAME_AW(CMDSTR_NEWFOLDER)")
1597 cpp_quote("#define CMDSTR_VIEWLIST WINELIB_NAME_AW(CMDSTR_VIEWLIST)")
1598 cpp_quote("#define CMDSTR_VIEWDETAILS WINELIB_NAME_AW(CMDSTR_VIEWDETAILS)")
1599
1600 cpp_quote("#define CMIC_MASK_HOTKEY SEE_MASK_HOTKEY")
1601 cpp_quote("#define CMIC_MASK_ICON SEE_MASK_ICON")
1602 cpp_quote("#define CMIC_MASK_FLAG_NO_UI SEE_MASK_FLAG_NO_UI")
1603 cpp_quote("#define CMIC_MASK_UNICODE SEE_MASK_UNICODE")
1604 cpp_quote("#define CMIC_MASK_NO_CONSOLE SEE_MASK_NO_CONSOLE")
1605 cpp_quote("#define CMIC_MASK_HASLINKNAME SEE_MASK_HASLINKNAME")
1606 cpp_quote("#define CMIC_MASK_FLAG_SEP_VDM SEE_MASK_FLAG_SEPVDM")
1607 cpp_quote("#define CMIC_MASK_HASTITLE SEE_MASK_HASTITLE")
1608 cpp_quote("#define CMIC_MASK_ASYNCOK SEE_MASK_ASYNCOK")
1609 cpp_quote("#define CMIC_MASK_NOASYNC SEE_MASK_NOASYNC")
1610 cpp_quote("#define CMIC_MASK_SHIFT_DOWN 0x10000000")
1611 cpp_quote("#define CMIC_MASK_PTINVOKE 0x20000000")
1612 cpp_quote("#define CMIC_MASK_CONTROL_DOWN 0x40000000")
1613 cpp_quote("#define CMIC_MASK_FLAG_LOG_USAGE SEE_MASK_FLAG_LOG_USAGE")
1614 cpp_quote("#define CMIC_MASK_NOZONECHECKS SEE_MASK_NOZONECHECKS")
1615
1616 typedef IContextMenu *LPCONTEXTMENU;
1617
1618 typedef struct tagCMINVOKECOMMANDINFO
1619 {
1620 DWORD cbSize;
1621 DWORD fMask;
1622 HWND hwnd;
1623 LPCSTR lpVerb;
1624 LPCSTR lpParameters;
1625 LPCSTR lpDirectory;
1626 INT nShow;
1627 DWORD dwHotKey;
1628 HANDLE hIcon;
1629 } CMINVOKECOMMANDINFO, *LPCMINVOKECOMMANDINFO;
1630
1631 typedef struct tagCMInvokeCommandInfoEx
1632 {
1633 DWORD cbSize;
1634 DWORD fMask;
1635 HWND hwnd;
1636 LPCSTR lpVerb;
1637 LPCSTR lpParameters;
1638 LPCSTR lpDirectory;
1639 INT nShow;
1640 DWORD dwHotKey;
1641 HANDLE hIcon;
1642 LPCSTR lpTitle;
1643 LPCWSTR lpVerbW;
1644 LPCWSTR lpParametersW;
1645 LPCWSTR lpDirectoryW;
1646 LPCWSTR lpTitleW;
1647 POINT ptInvoke;
1648 } CMINVOKECOMMANDINFOEX, *LPCMINVOKECOMMANDINFOEX;
1649
1650 HRESULT QueryContextMenu(
1651 [in] HMENU hmenu,
1652 [in] UINT indexMenu,
1653 [in] UINT idCmdFirst,
1654 [in] UINT idCmdLast,
1655 [in] UINT uFlags);
1656
1657 HRESULT InvokeCommand( [in] LPCMINVOKECOMMANDINFO lpici );
1658
1659 HRESULT GetCommandString(
1660 [in] UINT_PTR idCmd,
1661 [in] UINT uType,
1662 [out] UINT *pwReserved,
1663 [out, size_is(cchMax)] LPSTR pszName,
1664 [in] UINT cchMax);
1665 }
1666
1667
1668 /*****************************************************************************
1669 * IContextMenu2 interface
1670 */
1671 [
1672 object,
1673 uuid(000214f4-0000-0000-c000-000000000046),
1674 pointer_default(unique),
1675 local
1676 ]
1677 interface IContextMenu2 : IContextMenu
1678 {
1679 typedef IContextMenu2 *LPCONTEXTMENU2;
1680
1681 HRESULT HandleMenuMsg(
1682 [in] UINT uMsg,
1683 [in] WPARAM wParam,
1684 [in] LPARAM lParam);
1685 }
1686
1687
1688 /*****************************************************************************
1689 * IContextMenu3 interface
1690 */
1691 [
1692 object,
1693 uuid(bcfce0a0-ec17-11d0-8d10-00a0c90f2719),
1694 pointer_default(unique),
1695 local
1696 ]
1697 interface IContextMenu3 : IContextMenu2
1698 {
1699 typedef IContextMenu3 *LPCONTEXTMENU3;
1700
1701 HRESULT HandleMenuMsg2(
1702 [in] UINT uMsg,
1703 [in] WPARAM wParam,
1704 [in] LPARAM lParam,
1705 [out] LRESULT *plResult);
1706 }
1707
1708 /*****************************************************************************
1709 * IContextMenuCB interface
1710 */
1711
1712 [
1713 object,
1714 uuid(3409e930-5a39-11d1-83fa-00a0c90dc849),
1715 pointer_default(unique),
1716 local
1717 ]
1718 interface IContextMenuCB : IUnknown
1719 {
1720 HRESULT CallBack(
1721 [in] IShellFolder *psf,
1722 [in] HWND hwndOwner,
1723 [in] IDataObject *pdtobj,
1724 [in] UINT uMsg,
1725 [in] WPARAM wParam,
1726 [in] LPARAM lParam);
1727 }
1728
1729 /*****************************************************************************
1730 * IShellExecuteHookA interface
1731 */
1732 [
1733 object,
1734 uuid(000214f5-0000-0000-c000-000000000046),
1735 pointer_default(unique),
1736 local
1737 ]
1738 interface IShellExecuteHookA : IUnknown
1739 {
1740 cpp_quote("struct _SHELLEXECUTEINFOA;")
1741 HRESULT Execute(
1742 [in, out] struct _SHELLEXECUTEINFOA* pei);
1743 }
1744
1745
1746 /*****************************************************************************
1747 * IShellExecuteHookW interface
1748 */
1749 [
1750 object,
1751 uuid(000214fb-0000-0000-c000-000000000046),
1752 pointer_default(unique),
1753 local
1754 ]
1755 interface IShellExecuteHookW : IUnknown
1756 {
1757 cpp_quote("struct _SHELLEXECUTEINFOW;")
1758 HRESULT Execute(
1759 [in, out] struct _SHELLEXECUTEINFOW* pei);
1760 }
1761
1762 /*****************************************************************************
1763 * IShellLinkDataList interface
1764 */
1765 [
1766 object,
1767 uuid(45e2b4ae-b1c3-11d0-b92f-00a0c90312e1),
1768 pointer_default(unique)
1769 ]
1770 interface IShellLinkDataList : IUnknown
1771 {
1772 [local] HRESULT AddDataBlock(
1773 [in] void *pDataBlock);
1774 [local] HRESULT CopyDataBlock(
1775 [in] DWORD dwSig,
1776 [out] void **ppDataBlock);
1777 HRESULT RemoveDataBlock(
1778 [in] DWORD dwSig);
1779 HRESULT GetFlags(
1780 [out] DWORD *pdwFlags);
1781 HRESULT SetFlags(
1782 [in] DWORD dwFlags);
1783 }
1784
1785
1786 /*****************************************************************************
1787 * IResolveShellLink interface
1788 */
1789 [
1790 object,
1791 uuid(5cd52983-9449-11d2-963a-00c04f79adf0),
1792 pointer_default(unique)
1793 ]
1794 interface IResolveShellLink : IUnknown
1795 {
1796 HRESULT ResolveShellLink(
1797 [in] IUnknown *punk,
1798 [in] HWND hwnd,
1799 [in] DWORD fFlags);
1800 }
1801
1802
1803 /*****************************************************************************
1804 * IURLSearchHook interface
1805 */
1806 [
1807 object,
1808 uuid(ac60f6a0-0fd9-11d0-99cb-00c04fd64497),
1809 pointer_default(unique),
1810 local
1811 ]
1812 interface IURLSearchHook : IUnknown
1813 {
1814 HRESULT Translate(
1815 [in, out] LPWSTR lpwszSearchURL,
1816 [in] DWORD cchBufferSize);
1817 }
1818
1819
1820 /*****************************************************************************
1821 * ISearchContext interface
1822 */
1823 [
1824 object,
1825 uuid(09f656a2-41af-480c-88f7-16cc0d164615),
1826 pointer_default(unique),
1827 local
1828 ]
1829 interface ISearchContext : IUnknown
1830 {
1831 HRESULT GetSearchUrl(
1832 [in] BSTR *pbstrSearchUrl);
1833 HRESULT GetSearchText(
1834 [in] BSTR *pbstrSearchText);
1835 HRESULT GetSearchStyle(
1836 [in] BSTR *pdwSearchStyle);
1837 }
1838
1839
1840 /*****************************************************************************
1841 * IURLSearchHook2 interface
1842 */
1843 [
1844 object,
1845 uuid(5ee44da4-6d32-46e3-86bc-07540dedd0e0),
1846 pointer_default(unique),
1847 local
1848 ]
1849 interface IURLSearchHook2 : IURLSearchHook
1850 {
1851 HRESULT TranslateWithSearchContext(
1852 [in, out] LPWSTR lpwszSearchURL,
1853 [in] DWORD cchBufferSize,
1854 [in] ISearchContext *pSearchContext);
1855 }
1856
1857
1858 cpp_quote("#define INewShortcutHook WINELIB_NAME_AW(INewShortcutHook)")
1859
1860 /*****************************************************************************
1861 * INewShortcutHookA interface
1862 */
1863 [
1864 object,
1865 uuid(000214e1-0000-0000-c000-000000000046),
1866 pointer_default(unique),
1867 local
1868 ]
1869 interface INewShortcutHookA : IUnknown
1870 {
1871 HRESULT SetReferent(
1872 [in] LPCSTR pcszReferent,
1873 [in] HWND hwnd);
1874 HRESULT GetReferent(
1875 [out] LPSTR pcszReferent,
1876 [in] int cchReferent);
1877 HRESULT SetFolder(
1878 [in] LPCSTR pcszReferent);
1879 HRESULT GetFolder(
1880 [out] LPSTR pcszReferent,
1881 [in] int cchFolder);
1882 HRESULT GetName(
1883 [out] LPSTR pszName,
1884 [in] int cchName);
1885 HRESULT GetExtension(
1886 [out] LPSTR pszExtension,
1887 [in] int cchExtension);
1888 }
1889
1890
1891 /*****************************************************************************
1892 * INewShortcutHookW interface
1893 */
1894 [
1895 object,
1896 uuid(000214f7-0000-0000-c000-000000000046),
1897 pointer_default(unique),
1898 local
1899 ]
1900 interface INewShortcutHookW : IUnknown
1901 {
1902 HRESULT SetReferent(
1903 [in] LPCWSTR pcszReferent,
1904 [in] HWND hwnd);
1905 HRESULT GetReferent(
1906 [out] LPWSTR pcszReferent,
1907 [in] int cchReferent);
1908 HRESULT SetFolder(
1909 [in] LPCWSTR pcszReferent);
1910 HRESULT GetFolder(
1911 [out] LPWSTR pcszReferent,
1912 [in] int cchFolder);
1913 HRESULT GetName(
1914 [out] LPWSTR pszName,
1915 [in] int cchName);
1916 HRESULT GetExtension(
1917 [out] LPWSTR pszExtension,
1918 [in] int cchExtension);
1919 }
1920
1921 /*****************************************************************************
1922 * IRunnableTask interface
1923 */
1924 [
1925 object,
1926 uuid(85788d00-6807-11d0-b810-00c04fd706ec),
1927 pointer_default(unique),
1928 local
1929 ]
1930 interface IRunnableTask : IUnknown
1931 {
1932 HRESULT Run();
1933 HRESULT Kill([in] BOOL fWait);
1934 HRESULT Suspend();
1935 HRESULT Resume();
1936 ULONG IsRunning();
1937 }
1938
1939 /*****************************************************************************
1940 * IShellChangeNotify interface
1941 */
1942 [
1943 object,
1944 uuid(d82be2b1-5764-11d0-a96e-00c04fd705a2),
1945 pointer_default(unique),
1946 local
1947 ]
1948 interface IShellChangeNotify : IUnknown
1949 {
1950 HRESULT OnChange(
1951 [in] LONG lEvent,
1952 [in] LPCITEMIDLIST pidl1,
1953 [in] LPCITEMIDLIST pidl2);
1954 }
1955
1956 cpp_quote("#define STR_FILE_SYS_BIND_DATA L\"File System Bind Data\"")
1957
1958 /*****************************************************************************
1959 * IFileSystemBindData interface
1960 */
1961 [
1962 object,
1963 uuid(01e18d10-4d8b-11d2-855d-006008059367),
1964 pointer_default(unique),
1965 local
1966 ]
1967 interface IFileSystemBindData : IUnknown
1968 {
1969 HRESULT SetFindData(
1970 [in] const WIN32_FIND_DATAW *pfd);
1971 HRESULT GetFindData(
1972 [out] WIN32_FIND_DATAW *pfd);
1973 }
1974
1975 /*****************************************************************************
1976 * ITaskbarList interface
1977 */
1978 [
1979 object,
1980 uuid(56FDF342-FD6D-11d0-958A-006097C9A090),
1981 pointer_default(unique)
1982 ]
1983 interface ITaskbarList : IUnknown
1984 {
1985 HRESULT HrInit();
1986
1987 HRESULT AddTab(
1988 [in] HWND hwnd);
1989
1990 HRESULT DeleteTab(
1991 [in] HWND hwnd);
1992
1993 HRESULT ActivateTab(
1994 [in] HWND hwnd);
1995
1996 HRESULT SetActiveAlt(
1997 [in] HWND hwnd);
1998 }
1999
2000 /*****************************************************************************
2001 * IDefaultExtractIconInit interface
2002 */
2003
2004 [
2005 object,
2006 uuid(800AB0B8-F5FA-4e72-8FF3-B1A243B87BD9), /* FIXME: wrong value! */
2007 pointer_default(unique),
2008 local
2009 ]
2010 interface IDefaultExtractIconInit : IUnknown
2011 {
2012 HRESULT SetDefaultIcon(
2013 [in] LPCWSTR pszFile,
2014 [in] int iIcon);
2015 HRESULT SetFlags(
2016 [in] UINT uFlags);
2017 HRESULT SetKey(
2018 [in] HKEY hkey);
2019 HRESULT SetNormalIcon(
2020 [in] LPCWSTR pszFile,
2021 [in] int iIcon);
2022 HRESULT SetOpenIcon(
2023 [in] LPCWSTR pszFile,
2024 [in] int iIcon);
2025 HRESULT SetShortcutIcon(
2026 [in] LPCWSTR pszFile,
2027 [in] int iIcon);
2028 }
2029
2030 /*****************************************************************************
2031 * IDeskBand interface
2032 */
2033 cpp_quote("#define DBIM_MINSIZE 0x0001")
2034 cpp_quote("#define DBIM_MAXSIZE 0x0002")
2035 cpp_quote("#define DBIM_INTEGRAL 0x0004")
2036 cpp_quote("#define DBIM_ACTUAL 0x0008")
2037 cpp_quote("#define DBIM_TITLE 0x0010")
2038 cpp_quote("#define DBIM_MODEFLAGS 0x0020")
2039 cpp_quote("#define DBIM_BKCOLOR 0x0040")
2040
2041 cpp_quote("#include <pshpack8.h>")
2042
2043 typedef struct tagDESKBANDINFO
2044 {
2045 DWORD dwMask;
2046 POINTL ptMinSize;
2047 POINTL ptMaxSize;
2048 POINTL ptIntegral;
2049 POINTL ptActual;
2050 WCHAR wszTitle[256];
2051 DWORD dwModeFlags;
2052 COLORREF crBkgnd;
2053 } DESKBANDINFO;
2054
2055 cpp_quote("#include <poppack.h>")
2056
2057 cpp_quote("#define DBIMF_NORMAL 0x0000")
2058 cpp_quote("#define DBIMF_FIXED 0x0001")
2059 cpp_quote("#define DBIMF_FIXEDBMP 0x0004 // a fixed background bitmap (if supported)")
2060 cpp_quote("#define DBIMF_VARIABLEHEIGHT 0x0008")
2061 cpp_quote("#define DBIMF_UNDELETEABLE 0x0010")
2062 cpp_quote("#define DBIMF_DEBOSSED 0x0020")
2063 cpp_quote("#define DBIMF_BKCOLOR 0x0040")
2064 cpp_quote("#define DBIMF_USECHEVRON 0x0080")
2065 cpp_quote("#define DBIMF_BREAK 0x0100")
2066 cpp_quote("#define DBIMF_ADDTOFRONT 0x0200")
2067 cpp_quote("#define DBIMF_TOPALIGN 0x0400")
2068 cpp_quote("#if (NTDDI_VERSION >= NTDDI_LONGHORN)")
2069 cpp_quote("#define DBIMF_NOGRIPPER 0x0800")
2070 cpp_quote("#define DBIMF_ALWAYSGRIPPER 0x1000")
2071 cpp_quote("#define DBIMF_NOMARGINS 0x2000")
2072 cpp_quote("#endif // NTDDI_LONGHORN")
2073
2074 cpp_quote("#define DBIF_VIEWMODE_NORMAL 0x0000")
2075 cpp_quote("#define DBIF_VIEWMODE_VERTICAL 0x0001")
2076 cpp_quote("#define DBIF_VIEWMODE_FLOATING 0x0002")
2077 cpp_quote("#define DBIF_VIEWMODE_TRANSPARENT 0x0004")
2078
2079 enum tagDESKBANDCID {
2080 DBID_BANDINFOCHANGED = 0,
2081 DBID_SHOWONLY = 1,
2082 DBID_MAXIMIZEBAND = 2,
2083 DBID_PUSHCHEVRON = 3,
2084 DBID_DELAYINIT = 4,
2085 DBID_FINISHINIT = 5,
2086 DBID_SETWINDOWTHEME = 6,
2087 DBID_PERMITAUTOHIDE = 7,
2088 };
2089
2090 cpp_quote("#define DBPC_SELECTFIRST (DWORD)-1")
2091 cpp_quote("#define DBPC_SELECTLAST (DWORD)-2")
2092
2093 cpp_quote("#define CGID_DeskBand IID_IDeskBand")
2094
2095 [
2096 uuid(EB0FE172-1A3A-11D0-89B3-00A0C90A90AC),
2097 object,
2098 ]
2099 interface IDeskBand : IDockingWindow
2100 {
2101 HRESULT GetBandInfo(
2102 [in] DWORD dwBandID,
2103 [in] DWORD dwViewMode,
2104 [in, out] DESKBANDINFO* pdbi);
2105 }
2106
2107 cpp_quote("#if (_WIN32_IE >= _WIN32_IE_IE60)")
2108
2109 [
2110 uuid(EB0FE173-1A3A-11D0-89B3-00A0C90A90AC),
2111 object,
2112 pointer_default(unique),
2113 local
2114 ]
2115 interface IDeskBar : IOleWindow
2116 {
2117 HRESULT SetClient([in] IUnknown* punkClient);
2118
2119 HRESULT GetClient([out] IUnknown** ppunkClient);
2120
2121 HRESULT OnPosRectChangeDB([in] RECT *prc);
2122 }
2123
2124
2125 /*****************************************************************************
2126 * IMenuPopup interface
2127 */
2128 [
2129 uuid(D1E7AFEB-6A2E-11d0-8C78-00C04FD918B4),
2130 object,
2131 pointer_default(unique),
2132 local
2133 ]
2134 interface IMenuPopup : IDeskBar
2135 {
2136 enum tagMENUPOPUPSELECT
2137 {
2138 MPOS_EXECUTE = 0,
2139 MPOS_FULLCANCEL,
2140 MPOS_CANCELLEVEL,
2141 MPOS_SELECTLEFT,
2142 MPOS_SELECTRIGHT,
2143 MPOS_CHILDTRACKING
2144 };
2145
2146 enum tagMENUPOPUPPOPUPFLAGS
2147 {
2148 MPPF_SETFOCUS = 0x00000001,
2149 MPPF_INITIALSELECT = 0x00000002,
2150 MPPF_NOANIMATE = 0x00000004,
2151 MPPF_KEYBOARD = 0x00000010,
2152 MPPF_REPOSITION = 0x00000020,
2153 MPPF_FORCEZORDER = 0x00000040,
2154 MPPF_FINALSELECT = 0x00000080,
2155 MPPF_TOP = 0x20000000,
2156 MPPF_LEFT = 0x40000000,
2157 MPPF_RIGHT = 0x60000000,
2158 MPPF_BOTTOM = 0x80000000,
2159 MPPF_POS_MASK = 0xE0000000,
2160 MPPF_ALIGN_LEFT = 0x02000000,
2161 MPPF_ALIGN_RIGHT = 0x04000000
2162 };
2163 typedef int MP_POPUPFLAGS;
2164
2165 HRESULT Popup(
2166 [in] POINTL *ppt,
2167 [in] RECTL *prcExclude,
2168 [in] MP_POPUPFLAGS dwFlags);
2169
2170 HRESULT OnSelect([in] DWORD dwSelectType);
2171
2172 HRESULT SetSubMenu(
2173 [in] IMenuPopup* pmp,
2174 [in] BOOL fSet);
2175 }
2176
2177 cpp_quote("#endif /* _WIN32_IE_IE60 */")
2178
2179 cpp_quote("#if (_WIN32_IE >= _WIN32_IE_IE40)")
2180
2181 /*****************************************************************************
2182 * IBandSite interface
2183 */
2184 cpp_quote("#include <pshpack8.h>")
2185
2186 typedef struct tagBANDSITEINFO
2187 {
2188 DWORD dwMask;
2189 DWORD dwState;
2190 DWORD dwStyle;
2191 } BANDSITEINFO;
2192
2193 cpp_quote("#include <poppack.h>")
2194
2195
2196 enum tagBANDSITECID {
2197 BSID_BANDADDED,
2198 BSID_BANDREMOVED,
2199 };
2200
2201 cpp_quote("#define BSIM_STATE 0x00000001")
2202 cpp_quote("#define BSIM_STYLE 0x00000002")
2203
2204 cpp_quote("#define BSSF_VISIBLE 0x00000001")
2205 cpp_quote("#define BSSF_NOTITLE 0x00000002")
2206 cpp_quote("#define BSSF_UNDELETEABLE 0x00001000")
2207
2208 cpp_quote("#define BSIS_AUTOGRIPPER 0x00000000")
2209 cpp_quote("#define BSIS_NOGRIPPER 0x00000001")
2210 cpp_quote("#define BSIS_ALWAYSGRIPPER 0x00000002")
2211 cpp_quote("#define BSIS_LEFTALIGN 0x00000004")
2212 cpp_quote("#define BSIS_SINGLECLICK 0x00000008")
2213 cpp_quote("#define BSIS_NOCONTEXTMENU 0x00000010")
2214 cpp_quote("#define BSIS_NODROPTARGET 0x00000020")
2215 cpp_quote("#define BSIS_NOCAPTION 0x00000040")
2216 cpp_quote("#define BSIS_PREFERNOLINEBREAK 0x00000080")
2217 cpp_quote("#define BSIS_LOCKED 0x00000100")
2218 cpp_quote("#if (_WIN32_IE >= _WIN32_IE_IE70)")
2219 cpp_quote("#define BSIS_PRESERVEORDERDURINGLAYOUT 0x00000200")
2220 cpp_quote("#endif /* _WIN32_IE_IE70 */")
2221
2222 cpp_quote("#define SID_SBandSite IID_IBandSite")
2223 cpp_quote("#define CGID_BandSite IID_IBandSite")
2224
2225 [
2226 object,
2227 uuid(4CF504B0-DE96-11D0-8B3F-00A0C911E8E5)
2228 ]
2229 interface IBandSite : IUnknown
2230 {
2231 HRESULT AddBand([in] IUnknown* punk);
2232
2233 HRESULT EnumBands(
2234 [in] UINT uBand,
2235 [out] DWORD* pdwBandID);
2236
2237 HRESULT QueryBand(
2238 [in] DWORD dwBandID,
2239 [out] IDeskBand** ppstb,
2240 [out] DWORD* pdwState,
2241 [out, string, size_is(cchName)] LPWSTR pszName,
2242 [in] int cchName);
2243
2244 HRESULT SetBandState(
2245 [in] DWORD dwBandID,
2246 [in] DWORD dwMask,
2247 [in] DWORD dwState);
2248
2249 HRESULT RemoveBand([in] DWORD dwBandID);
2250
2251 HRESULT GetBandObject(
2252 [in] DWORD dwBandID,
2253 [in] REFIID riid,
2254 [out, iid_is(riid)] void **ppv);
2255
2256 HRESULT SetBandSiteInfo([in] const BANDSITEINFO *pbsinfo);
2257
2258 HRESULT GetBandSiteInfo([in, out] BANDSITEINFO *pbsinfo);
2259 }
2260
2261 cpp_quote("#endif /* _WIN32_IE_IE40 */")
2262
2263 /*****************************************************************************
2264 * IMenuBand interface
2265 */
2266 [
2267 uuid(568804CD-CBD7-11d0-9816-00C04FD91972),
2268 object,
2269 pointer_default(unique),
2270 local
2271 ]
2272 interface IMenuBand : IUnknown
2273 {
2274 enum tagMENUBANDHANDLERCID {
2275 MBHANDCID_PIDLSELECT = 0,
2276 };
2277
2278 HRESULT IsMenuMessage([in] MSG* pmsg);
2279
2280 HRESULT TranslateMenuMessage(
2281 [in, out] MSG* pmsg,
2282 [out] LRESULT* plRet);
2283 }
2284
2285 /*****************************************************************************
2286 * IProfferService interface
2287 */
2288 [
2289 uuid(cb728b20-f786-11ce-92ad-00aa00a74cd0),
2290 object,
2291 pointer_default(unique),
2292 local
2293 ]
2294 interface IProfferService : IUnknown
2295 {
2296 HRESULT ProfferService(
2297 [in] REFGUID service,
2298 [in] IServiceProvider *pService,
2299 [out] DWORD *pCookie);
2300
2301 HRESULT RevokeService([in] DWORD cookie);
2302 }
2303
2304 /*****************************************************************************
2305 * IShellMenuCallback interface
2306 */
2307 cpp_quote("#include <pshpack8.h>")
2308
2309 typedef struct tagSMDATA
2310 {
2311 DWORD dwMask;
2312 DWORD dwFlags;
2313 HMENU hmenu;
2314 HWND hwnd;
2315 UINT uId;
2316 UINT uIdParent;
2317 UINT uIdAncestor;
2318 IUnknown *punk;
2319 LPITEMIDLIST pidlFolder;
2320 LPITEMIDLIST pidlItem;
2321 IShellFolder *psf;
2322 void *pvUserData;
2323 } SMDATA, *LPSMDATA;
2324
2325 cpp_quote("#define SMDM_SHELLFOLDER 0x00000001")
2326 cpp_quote("#define SMDM_HMENU 0x00000002")
2327 cpp_quote("#define SMDM_TOOLBAR 0x00000004")
2328
2329 typedef struct tagSMINFO
2330 {
2331 DWORD dwMask;
2332 DWORD dwType;
2333 DWORD dwFlags;
2334 int iIcon;
2335 } SMINFO, *PSMINFO;
2336
2337 typedef struct tagSHCSCHANGENOTIFYSTRUCT
2338 {
2339 LONG lEvent;
2340 LPCITEMIDLIST pidl1;
2341 LPCITEMIDLIST pidl2;
2342 } SMCSHCHANGENOTIFYSTRUCT, *PSMCSHCHANGENOTIFYSTRUCT;
2343
2344 cpp_quote("#include <poppack.h>")
2345
2346 enum
2347 {
2348 SMIM_TYPE = 0x00000001,
2349 SMIM_FLAGS = 0x00000002,
2350 SMIM_ICON = 0x00000004
2351 };
2352
2353 enum
2354 {
2355 SMIT_SEPARATOR = 0x00000001,
2356 SMIT_STRING = 0x00000002
2357 };
2358
2359 enum
2360 {
2361 SMIF_ICON = 0x00000001,
2362 SMIF_ACCELERATOR = 0x00000002,
2363 SMIF_DROPTARGET = 0x00000004,
2364 SMIF_SUBMENU = 0x00000008,
2365 SMIF_CHECKED = 0x00000020,
2366 SMIF_DROPCASCADE = 0x00000040,
2367 SMIF_HIDDEN = 0x00000080,
2368 SMIF_DISABLED = 0x00000100,
2369 SMIF_TRACKPOPUP = 0x00000200,
2370 SMIF_DEMOTED = 0x00000400,
2371 SMIF_ALTSTATE = 0x00000800,
2372 SMIF_DRAGNDROP = 0x00001000,
2373 SMIF_NEW = 0x00002000,
2374 };
2375
2376
2377 cpp_quote("#define SMC_INITMENU 0x00000001")
2378 cpp_quote("#define SMC_CREATE 0x00000002")
2379 cpp_quote("#define SMC_EXITMENU 0x00000003")
2380 cpp_quote("#define SMC_GETINFO 0x00000005")
2381 cpp_quote("#define SMC_GETSFINFO 0x00000006")
2382 cpp_quote("#define SMC_GETOBJECT 0x00000007")
2383 cpp_quote("#define SMC_GETSFOBJECT 0x00000008")
2384 cpp_quote("#define SMC_SFEXEC 0x00000009")
2385 cpp_quote("#define SMC_SFSELECTITEM 0x0000000A")
2386 cpp_quote("#define SMC_REFRESH 0x00000010")
2387 cpp_quote("#define SMC_DEMOTE 0x00000011")
2388 cpp_quote("#define SMC_PROMOTE 0x00000012")
2389 cpp_quote("#define SMC_DEFAULTICON 0x00000016")
2390 cpp_quote("#define SMC_NEWITEM 0x00000017")
2391 cpp_quote("#define SMC_CHEVRONEXPAND 0x00000019")
2392 cpp_quote("#define SMC_DISPLAYCHEVRONTIP 0x0000002A")
2393 cpp_quote("#define SMC_SETSFOBJECT 0x0000002D")
2394 cpp_quote("#define SMC_SHCHANGENOTIFY 0x0000002E")
2395 cpp_quote("#define SMC_CHEVRONGETTIP 0x0000002F")
2396 cpp_quote("#define SMC_SFDDRESTRICTED 0x00000030")
2397
2398 [
2399 uuid(4CA300A1-9B8D-11d1-8B22-00C04FD918D0),
2400 object,
2401 pointer_default(unique),
2402 local
2403 ]
2404 interface IShellMenuCallback : IUnknown
2405 {
2406 HRESULT CallbackSM(
2407 [in, out] LPSMDATA psmd,
2408 [in] UINT uMsg,
2409 [in] WPARAM wParam,
2410 [in] LPARAM lParam);
2411 }
2412
2413
2414 /*****************************************************************************
2415 * IShellMenu interface
2416 */
2417
2418 cpp_quote("#define SMINIT_DEFAULT 0x00000000")
2419 cpp_quote("#define SMINIT_RESTRICT_DRAGDROP 0x00000002")
2420 cpp_quote("#define SMINIT_TOPLEVEL 0x00000004")
2421 cpp_quote("#define SMINIT_CACHED 0x00000010")
2422 cpp_quote("#define SMINIT_VERTICAL 0x10000000")
2423 cpp_quote("#define SMINIT_HORIZONTAL 0x20000000")
2424 cpp_quote("")
2425 cpp_quote("#define ANCESTORDEFAULT (UINT)-1")
2426 cpp_quote("")
2427 cpp_quote("#define SMSET_TOP 0x10000000")
2428 cpp_quote("#define SMSET_BOTTOM 0x20000000")
2429 cpp_quote("#define SMSET_DONTOWN 0x00000001")
2430 cpp_quote("")
2431 cpp_quote("#define SMINV_REFRESH 0x00000001")
2432 cpp_quote("#define SMINV_ID 0x00000008")
2433
2434 [
2435 uuid(EE1F7637-E138-11d1-8379-00C04FD918D0),
2436 object,
2437 pointer_default(unique),
2438 local
2439 ]
2440 interface IShellMenu : IUnknown
2441 {
2442 HRESULT Initialize(
2443 [in] IShellMenuCallback *psmc,
2444 [in] UINT uId,
2445 [in] UINT uIdAncestor,
2446 [in] DWORD dwFlags);
2447
2448 HRESULT GetMenuInfo(
2449 [out] IShellMenuCallback **ppsmc,
2450 [out] UINT *puId,
2451 [out] UINT *puIdAncestor,
2452 [out] DWORD *pdwFlags);
2453
2454 HRESULT SetShellFolder(
2455 [in] IShellFolder *psf,
2456 [in] LPCITEMIDLIST pidlFolder,
2457 [in] HKEY hKey,
2458 [in] DWORD dwFlags);
2459
2460 HRESULT GetShellFolder(
2461 [out] DWORD *pdwFlags,
2462 [out] LPITEMIDLIST *ppidl,
2463 [in] REFIID riid,
2464 [out] void **ppv);
2465
2466 HRESULT SetMenu(
2467 [in] HMENU hmenu,
2468 [in] HWND hwnd,
2469 [in] DWORD dwFlags);
2470
2471 HRESULT GetMenu(
2472 [out] HMENU *phmenu,
2473 [out] HWND *phwnd,
2474 [out] DWORD *pdwFlags);
2475
2476 HRESULT InvalidateItem(
2477 [in] LPSMDATA psmd,
2478 [in] DWORD dwFlags);
2479
2480 HRESULT GetState(
2481 [out] LPSMDATA psmd);
2482
2483 HRESULT SetMenuToolbar(
2484 [in] IUnknown *punk,
2485 [in] DWORD dwFlags);
2486 }
2487
2488 cpp_quote("#if (_WIN32_IE >= _WIN32_IE_IE60)")
2489
2490 /*****************************************************************************
2491 * ITrackShellMenu interface
2492 */
2493 [
2494 uuid(8278F932-2A3E-11d2-838F-00C04FD918D0),
2495 object,
2496 pointer_default(unique),
2497 local
2498 ]
2499 interface ITrackShellMenu : IShellMenu
2500 {
2501 HRESULT SetObscured(
2502 [in] HWND hwndTB,
2503 [in] IUnknown *punkBand,
2504 DWORD dwSMSetFlags);
2505
2506 HRESULT Popup(
2507 [in] HWND hwnd,
2508 [in] POINTL *ppt,
2509 [in] RECTL *prcExclude,
2510 MP_POPUPFLAGS dwFlags);
2511 };
2512
2513 cpp_quote("#endif /* _WIN32_IE_IE60 */")
2514
2515 cpp_quote("#ifdef MIDL_PASS")
2516 typedef IUnknown* HIMAGELIST;
2517 cpp_quote("#endif")
2518
2519 typedef [v1_enum] enum THUMBBUTTONFLAGS {
2520 THBF_ENABLED = 0x0000,
2521 THBF_DISABLED = 0x0001,
2522 THBF_DISMISSONCLICK = 0x0002,
2523 THBF_NOBACKGROUND = 0x0004,
2524 THBF_HIDDEN = 0x0008,
2525 THBF_NONINTERACTIVE = 0x0010
2526 } THUMBBUTTONFLAGS;
2527
2528 cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(THUMBBUTTONFLAGS)")
2529
2530 typedef [v1_enum] enum THUMBBUTTONMASK {
2531 THB_BITMAP = 0x0001,
2532 THB_ICON = 0x0002,
2533 THB_TOOLTIP = 0x0004,
2534 THB_FLAGS = 0x0008
2535 } THUMBBUTTONMASK;
2536
2537 cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(THUMBBUTTONMASK)")
2538
2539 cpp_quote("#include <pshpack8.h>")
2540 typedef struct THUMBBUTTON {
2541 THUMBBUTTONMASK dwMask;
2542 UINT iId;
2543 UINT iBitmap;
2544 HICON hIcon;
2545 WCHAR szTip[260];
2546 THUMBBUTTONFLAGS dwFlags;
2547 } THUMBBUTTON, *LPTHUMBBUTTON;
2548 cpp_quote("#include <poppack.h>")
2549
2550 /*****************************************************************************
2551 * ITaskbarList2 interface
2552 */
2553 [
2554 object,
2555 uuid(602D4995-B13A-429B-A66E-1935E44F4317),
2556 pointer_default(unique)
2557 ]
2558 interface ITaskbarList2 : ITaskbarList
2559 {
2560 HRESULT MarkFullscreenWindow(
2561 [in] HWND hwnd,
2562 [in] BOOL fullscreen);
2563 }
2564
2565 [
2566 uuid(ea1afb91-9e28-4b86-90e9-9e9f8a5eefaf),
2567 object
2568 ]
2569 interface ITaskbarList3 : ITaskbarList2
2570 {
2571 typedef [v1_enum] enum TBPFLAG {
2572 TBPF_NOPROGRESS = 0x0000,
2573 TBPF_INDETERMINATE = 0x0001,
2574 TBPF_NORMAL = 0x0002,
2575 TBPF_ERROR = 0x0004,
2576 TBPF_PAUSED = 0x0008
2577 } TBPFLAG;
2578
2579 cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(TBPFLAG)")
2580
2581 HRESULT SetProgressValue(
2582 [in] HWND hwnd,
2583 [in] ULONGLONG ullCompleted,
2584 [in] ULONGLONG ullTotal);
2585
2586 HRESULT SetProgressState(
2587 [in] HWND hwnd,
2588 [in] TBPFLAG tbpFlags);
2589
2590 HRESULT RegisterTab(
2591 [in] HWND hwndTab,
2592 [in] HWND hwndMDI);
2593
2594 HRESULT UnregisterTab([in] HWND hwndTab);
2595
2596 HRESULT SetTabOrder(
2597 [in] HWND hwndTab,
2598 [in] HWND hwndInsertBefore);
2599
2600 HRESULT SetTabActive(
2601 [in] HWND hwndTab,
2602 [in] HWND hwndMDI,
2603 [in] DWORD dwReserved);
2604
2605 HRESULT ThumbBarAddButtons(
2606 [in] HWND hwnd,
2607 [in] UINT cButtons,
2608 [in, size_is(cButtons)] LPTHUMBBUTTON pButton);
2609
2610 HRESULT ThumbBarUpdateButtons(
2611 [in] HWND hwnd,
2612 [in] UINT cButtons,
2613 [in, size_is(cButtons)] LPTHUMBBUTTON pButton);
2614
2615 HRESULT ThumbBarSetImageList(
2616 [in] HWND hwnd,
2617 [in] HIMAGELIST himl);
2618
2619 HRESULT SetOverlayIcon(
2620 [in] HWND hwnd,
2621 [in] HICON hIcon,
2622 [in, unique, string] LPCWSTR pszDescription);
2623
2624 HRESULT SetThumbnailTooltip(
2625 [in] HWND hwnd,
2626 [in, unique, string] LPCWSTR pszTip);
2627
2628 HRESULT SetThumbnailClip(
2629 [in] HWND hwnd,
2630 [in] RECT *prcClip);
2631 }
2632
2633 [
2634 uuid(c43dc798-95d1-4bea-9030-bb99e2983a1a),
2635 object
2636 ]
2637 interface ITaskbarList4 : ITaskbarList3
2638 {
2639 typedef [v1_enum] enum STPFLAG {
2640 STPF_NONE = 0x0000,
2641 STPF_USEAPPTHUMBNAILALWAYS = 0x0001,
2642 STPF_USEAPPTHUMBNAILWHENACTIVE = 0x0002,
2643 STPF_USEAPPPEEKALWAYS = 0x0004,
2644 STPF_USEAPPPEEKWHENACTIVE = 0x0008
2645 } STPFLAG;
2646
2647 cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(STPFLAG)")
2648
2649 HRESULT SetTabProperties(
2650 [in] HWND hwndTab,
2651 [in] STPFLAG stpFlags);
2652 }
2653
2654 /*****************************************************************************
2655 * IAutoCompleteDropDown interface
2656 */
2657 [
2658 object,
2659 uuid(3CD141F4-3C6A-11d2-BCAA-00C04FD929DB),
2660 pointer_default(unique)
2661 ]
2662 interface IAutoCompleteDropDown : IUnknown
2663 {
2664 cpp_quote("#define ACDD_VISIBLE 0x0001")
2665
2666 HRESULT GetDropDownStatus(
2667 [out] DWORD *pdwFlags,
2668 [out, string] LPWSTR *ppwszString);
2669
2670 HRESULT ResetEnumerator();
2671 }
2672
2673 /*****************************************************************************
2674 * IExplorerBrowserEvents interface
2675 */
2676 [
2677 object,
2678 uuid(361BBDC7-E6EE-4E13-BE58-58E2240C810F)
2679 ]
2680 interface IExplorerBrowserEvents : IUnknown
2681 {
2682 HRESULT OnNavigationPending(
2683 [in] PCIDLIST_ABSOLUTE pidlFolder);
2684
2685 HRESULT OnViewCreated(
2686 [in] IShellView *psv);
2687
2688 HRESULT OnNavigationComplete(
2689 [in] PCIDLIST_ABSOLUTE pidlFolder);
2690
2691 HRESULT OnNavigationFailed(
2692 [in] PCIDLIST_ABSOLUTE pidlFolder);
2693 }
2694
2695 typedef GUID EXPLORERPANE;
2696 typedef EXPLORERPANE *REFEXPLORERPANE;
2697
2698 cpp_quote("#define SID_ExplorerPaneVisibility IID_IExplorerPaneVisibility")
2699
2700 /*****************************************************************************
2701 * IExplorerPaneVisibility interface
2702 */
2703 [
2704 object,
2705 uuid(E07010EC-BC17-44C0-97B0-46C7C95B9EDC)
2706 ]
2707 interface IExplorerPaneVisibility : IUnknown
2708 {
2709 typedef enum tagEXPLORERPANESTATE {
2710 EPS_DONTCARE = 0x0,
2711 EPS_DEFAULT_ON = 0x1,
2712 EPS_DEFAULT_OFF = 0x2,
2713 EPS_STATE_MASK = 0xffff,
2714 EPS_INITIALSTATE = 0x10000,
2715 EPS_FORCE = 0x20000
2716 } EXPLORERPANESTATE;
2717
2718 HRESULT GetPaneState(
2719 [in] REFEXPLORERPANE ep,
2720 [out] EXPLORERPANESTATE *peps);
2721 }
2722
2723 typedef [v1_enum] enum tagEXPLORER_BROWSER_FILL_FLAGS {
2724 EBF_NONE = 0,
2725 EBF_SELECTFROMDATAOBJECT = 0x100,
2726 EBF_NODROPTARGET = 0x200
2727 } EXPLORER_BROWSER_FILL_FLAGS;
2728
2729 typedef [v1_enum] enum tagEXPLORER_BROWSER_OPTIONS {
2730 EBO_NONE = 0x00,
2731 EBO_NAVIGATEONCE = 0x01,
2732 EBO_SHOWFRAMES = 0x02,
2733 EBO_ALWAYSNAVIGATE = 0x04,
2734 EBO_NOTRAVELLOG = 0x08,
2735 EBO_NOWRAPPERWINDOW = 0x10,
2736 EBO_HTMLSHAREPOINTVIEW = 0x20
2737 } EXPLORER_BROWSER_OPTIONS;
2738
2739 cpp_quote("#define SID_SExplorerBrowserFrame IID_ICommDlgBrowser")
2740
2741 /*****************************************************************************
2742 * IExplorerBrowser interface
2743 */
2744 [
2745 object,
2746 uuid(DFD3B6B5-C10C-4BE9-85F6-A66969F402F6),
2747 pointer_default(unique)
2748 ]
2749 interface IExplorerBrowser : IUnknown
2750 {
2751
2752 [local] HRESULT Initialize(
2753 [in] HWND hwndParent,
2754 [in] const RECT *prc,
2755 [in, unique] const FOLDERSETTINGS *pfs);
2756
2757 HRESULT Destroy();
2758
2759 [local] HRESULT SetRect(
2760 [in,out,unique] HDWP *phdwp,
2761 [in] RECT rcBrowser);
2762
2763 HRESULT SetPropertyBag(
2764 [in, string] LPCWSTR pszPropertyBag);
2765
2766 HRESULT SetEmptyText(
2767 [in, string] LPCWSTR pszEmptyText);
2768
2769 HRESULT SetFolderSettings(
2770 [in] const FOLDERSETTINGS *pfs);
2771
2772 HRESULT Advise(
2773 [in] IExplorerBrowserEvents *psbe,
2774 [out] DWORD *pdwCookie);
2775
2776 HRESULT Unadvise(
2777 [in] DWORD dwCookie);
2778
2779 HRESULT SetOptions(
2780 [in] EXPLORER_BROWSER_OPTIONS dwFlag);
2781
2782 HRESULT GetOptions(
2783 [out] EXPLORER_BROWSER_OPTIONS *pdwFlag);
2784
2785 HRESULT BrowseToIDList(
2786 [in] PCUIDLIST_RELATIVE pidl,
2787 [in] UINT uFlags);
2788
2789 HRESULT BrowseToObject(
2790 [in] IUnknown *punk,
2791 [in] UINT uFlags);
2792
2793 HRESULT FillFromObject(
2794 [in] IUnknown *punk,
2795 [in] EXPLORER_BROWSER_FILL_FLAGS dwFlags);
2796
2797 HRESULT RemoveAll();
2798
2799 HRESULT GetCurrentView(
2800 [in] REFIID riid,
2801 [out, iid_is(riid)] void **ppv);
2802 }
2803
2804 /*****************************************************************************
2805 * INameSpaceTreeControl interface
2806 */
2807 [
2808 object,
2809 uuid(028212A3-B627-47E9-8856-C14265554E4F)
2810 ]
2811 interface INameSpaceTreeControl : IUnknown
2812 {
2813 [v1_enum] enum _NSTCSTYLE {
2814 NSTCS_HASEXPANDOS = 0x00000001,
2815 NSTCS_HASLINES = 0x00000002,
2816 NSTCS_SINGLECLICKEXPAND = 0x00000004,
2817 NSTCS_FULLROWSELECT = 0x00000008,
2818 NSTCS_SPRINGEXPAND = 0x00000010,
2819 NSTCS_HORIZONTALSCROLL = 0x00000020,
2820 NSTCS_ROOTHASEXPANDO = 0x00000040,
2821 NSTCS_SHOWSELECTIONALWAYS = 0x00000080,
2822 NSTCS_NOINFOTIP = 0x00000200,
2823 NSTCS_EVENHEIGHT = 0x00000400,
2824 NSTCS_NOREPLACEOPEN = 0x00000800,
2825 NSTCS_DISABLEDRAGDROP = 0x00001000,
2826 NSTCS_NOORDERSTREAM = 0x00002000,
2827 NSTCS_RICHTOOLTIP = 0x00004000,
2828 NSTCS_BORDER = 0x00008000,
2829 NSTCS_NOEDITLABELS = 0x00010000,
2830 NSTCS_TABSTOP = 0x00020000,
2831 NSTCS_FAVORITESMODE = 0x00080000,
2832 NSTCS_AUTOHSCROLL = 0x00100000,
2833 NSTCS_FADEINOUTEXPANDOS = 0x00200000,
2834 NSTCS_EMPTYTEXT = 0x00400000,
2835 NSTCS_CHECKBOXES = 0x00800000,
2836 NSTCS_PARTIALCHECKBOXES = 0x01000000,
2837 NSTCS_EXCLUSIONCHECKBOXES = 0x02000000,
2838 NSTCS_DIMMEDCHECKBOXES = 0x04000000,
2839 NSTCS_NOINDENTCHECKS = 0x08000000,
2840 NSTCS_ALLOWJUNCTIONS = 0x10000000,
2841 NSTCS_SHOWTABSBUTTON = 0x20000000,
2842 NSTCS_SHOWDELETEBUTTON = 0x40000000,
2843 NSTCS_SHOWREFRESHBUTTON = (int)0x80000000
2844 };
2845 typedef DWORD NSTCSTYLE;
2846
2847 [v1_enum] enum _NSTCROOTSTYLE {
2848 NSTCRS_VISIBLE = 0x0000,
2849 NSTCRS_HIDDEN = 0x0001,
2850 NSTCRS_EXPANDED = 0x0002
2851 };
2852 typedef DWORD NSTCROOTSTYLE;
2853
2854 [v1_enum] enum _NSTCITEMSTATE {
2855 NSTCIS_NONE = 0x0000,
2856 NSTCIS_SELECTED = 0x0001,
2857 NSTCIS_EXPANDED = 0x0002,
2858 NSTCIS_BOLD = 0x0004,
2859 NSTCIS_DISABLED = 0x0008,
2860 NSTCIS_SELECTEDNOEXPAND = 0x0010
2861 };
2862 typedef DWORD NSTCITEMSTATE;
2863
2864 typedef [v1_enum] enum NSTCGNI {
2865 NSTCGNI_NEXT = 0,
2866 NSTCGNI_NEXTVISIBLE = 1,
2867 NSTCGNI_PREV = 2,
2868 NSTCGNI_PREVVISIBLE = 3,
2869 NSTCGNI_PARENT = 4,
2870 NSTCGNI_CHILD = 5,
2871 NSTCGNI_FIRSTVISIBLE = 6,
2872 NSTCGNI_LASTVISIBLE = 7
2873 } NSTCGNI;
2874
2875 HRESULT Initialize(
2876 [in] HWND hwndParent,
2877 [in, unique] RECT *prc,
2878 [in] NSTCSTYLE nstcsFlags);
2879
2880 HRESULT TreeAdvise(
2881 [in] IUnknown *punk,
2882 [out] DWORD *pdwCookie);
2883
2884 HRESULT TreeUnadvise(
2885 [in] DWORD dwCookie);
2886
2887 HRESULT AppendRoot(
2888 [in] IShellItem *psiRoot,
2889 [in] SHCONTF grfEnumFlags,
2890 [in] NSTCROOTSTYLE grfRootStyle,
2891 [in, unique] IShellItemFilter *pif);
2892
2893 HRESULT InsertRoot(
2894 [in] int iIndex,
2895 [in] IShellItem *psiRoot,
2896 [in] SHCONTF grfEnumFlags,
2897 [in] NSTCROOTSTYLE grfRootStyle,
2898 [in, unique] IShellItemFilter *pif);
2899
2900 HRESULT RemoveRoot(
2901 [in] IShellItem *psiRoot);
2902
2903 HRESULT RemoveAllRoots();
2904
2905 HRESULT GetRootItems(
2906 [out] IShellItemArray **ppsiaRootItems);
2907
2908 HRESULT SetItemState(
2909 [in] IShellItem *psi,
2910 [in] NSTCITEMSTATE nstcisMask,
2911 [in] NSTCITEMSTATE nstcisFlags);
2912
2913 HRESULT GetItemState(
2914 [in] IShellItem *psi,
2915 [in] NSTCITEMSTATE nstcismask,
2916 [out] NSTCITEMSTATE *pnstcisFlags);
2917
2918 HRESULT GetSelectedItems(
2919 [out] IShellItemArray **psiaItems);
2920
2921 HRESULT GetItemCustomState(
2922 [in] IShellItem *psi,
2923 [out] int *piStateNumber);
2924
2925 HRESULT SetItemCustomState(
2926 [in] IShellItem *psi,
2927 [in] int iStateNumber);
2928
2929 HRESULT EnsureItemVisible(
2930 [in] IShellItem *psi);
2931
2932 HRESULT SetTheme(
2933 [in, string] LPCWSTR pszTheme);
2934
2935 HRESULT GetNextItem(
2936 [in, unique] IShellItem *psi,
2937 [in] NSTCGNI nstcgi,
2938 [out] IShellItem **ppsiNext);
2939
2940 HRESULT HitTest(
2941 [in] POINT *ppt,
2942 [out] IShellItem **ppsiOut);
2943
2944 HRESULT GetItemRect(
2945 [in] IShellItem *psi,
2946 [out] RECT *prect);
2947
2948 HRESULT CollapseAll();
2949 }
2950
2951 /*****************************************************************************
2952 * INameSpaceTreeControl2 interface
2953 */
2954 [
2955 object,
2956 uuid(7CC7AED8-290E-49BC-8945-C1401CC9306C)
2957 ]
2958 interface INameSpaceTreeControl2 : INameSpaceTreeControl
2959 {
2960 typedef [v1_enum] enum NSTCSTYLE2 {
2961 NSTCS2_DEFAULT = 0x00,
2962 NSTCS2_INTERRUPTNOTIFICATIONS = 0x01,
2963 NSTCS2_SHOWNULLSPACEMENU = 0x02,
2964 NSTCS2_DISPLAYPADDING = 0x04,
2965 NSTCS2_DISPLAYPINNEDONLY = 0x08,
2966 NTSCS2_NOSINGLETONAUTOEXPAND = 0x10, /* The apparent typo here is */
2967 NTSCS2_NEVERINSERTNONENUMERATED = 0x20 /* present also in the Win SDK */
2968 } NSTCSTYLE2;
2969 cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(NSTCSTYLE2)")
2970
2971 HRESULT SetControlStyle(
2972 [in] NSTCSTYLE nstcsMask,
2973 [in] NSTCSTYLE nstcsStyle);
2974
2975 HRESULT GetControlStyle(
2976 [in] NSTCSTYLE nstcsMask,
2977 [out] NSTCSTYLE *pnstcsStyle);
2978
2979 HRESULT SetControlStyle2(
2980 [in] NSTCSTYLE2 nstcsMask,
2981 [in] NSTCSTYLE2 nstcsStyle);
2982
2983 HRESULT GetControlStyle2(
2984 [in] NSTCSTYLE2 nstcsMask,
2985 [out] NSTCSTYLE2 *pnstcsStyle);
2986 }
2987
2988 /*****************************************************************************
2989 * INameSpaceTreeControlEvents interface
2990 */
2991
2992 [
2993 object,
2994 uuid(93D77985-B3D8-4484-8318-672CDDA002CE),
2995 local
2996 ]
2997 interface INameSpaceTreeControlEvents : IUnknown
2998 {
2999 [v1_enum] enum _NSTCEHITTEST {
3000 NSTCEHT_NOWHERE = 0x0001,
3001 NSTCEHT_ONITEMICON = 0x0002,
3002 NSTCEHT_ONITEMLABEL = 0x0004,
3003 NSTCEHT_ONITEMIDENT = 0x0008,
3004 NSTCEHT_ONITEMBUTTON = 0x0010,
3005 NSTCEHT_ONITEMRIGHT = 0x0020,
3006 NSTCEHT_ONITEMSTATEICON = 0x0040,
3007 NSTCEHT_ONITEM = 0x0046,
3008 NSTCEHT_ONITEMTABBUTTON = 0x1000
3009 };
3010 typedef DWORD NSTCEHITTEST;
3011
3012 [v1_enum] enum _NSTCECLICKTYPE {
3013 NSTCECT_LBUTTON = 0x1,
3014 NSTCECT_MBUTTON = 0x2,
3015 NSTCECT_RBUTTON = 0x3,
3016 NSTCECT_BUTTON = 0x3,
3017 NSTCECT_DBLCLICK = 0x4
3018 };
3019 typedef DWORD NSTCECLICKTYPE;
3020
3021 HRESULT OnItemClick(
3022 [in] IShellItem *psi,
3023 [in] NSTCEHITTEST nstceHitTest,
3024 [in] NSTCECLICKTYPE nstceClickType);
3025
3026 HRESULT OnPropertyItemCommit(
3027 [in] IShellItem *psi);
3028
3029 HRESULT OnItemStateChanging(
3030 [in] IShellItem *psi,
3031 [in] NSTCITEMSTATE nstcisMask,
3032 [in] NSTCITEMSTATE nstcisState);
3033
3034 HRESULT OnItemStateChanged(
3035 [in] IShellItem *psi,
3036 [in] NSTCITEMSTATE nstcisMask,
3037 [in] NSTCITEMSTATE nstcisState);
3038
3039 HRESULT OnSelectionChanged(
3040 [in] IShellItemArray *psiaSelection);
3041
3042 HRESULT OnKeyboardInput(
3043 [in] UINT uMsg,
3044 [in] WPARAM wParam,
3045 [in] LPARAM lParam);
3046
3047 HRESULT OnBeforeExpand(
3048 [in] IShellItem *psi);
3049
3050 HRESULT OnAfterExpand(
3051 [in] IShellItem *psi);
3052
3053 HRESULT OnBeginLabelEdit(
3054 [in] IShellItem *psi);
3055
3056 HRESULT OnEndLabelEdit(
3057 [in] IShellItem *psi);
3058
3059 HRESULT OnGetToolTip(
3060 [in] IShellItem *psi,
3061 [out, string, size_is(cchTip)] LPWSTR pszTip,
3062 [in] int cchTip);
3063
3064 HRESULT OnBeforeItemDelete(
3065 [in] IShellItem *psi);
3066
3067 HRESULT OnItemAdded(
3068 [in] IShellItem *psi,
3069 [in] BOOL fIsRoot);
3070
3071 HRESULT OnItemDeleted(
3072 [in] IShellItem *psi,
3073 [in] BOOL fIsRoot);
3074
3075 HRESULT OnBeforeContextMenu(
3076 [in, unique] IShellItem *psi,
3077 [in] REFIID riid,
3078 [out, iid_is(riid)] void **ppv);
3079
3080 HRESULT OnAfterContextMenu(
3081 [in] IShellItem *psi,
3082 [in] IContextMenu *pcmIn,
3083 [in] REFIID riid,
3084 [out, iid_is(riid)] void **ppv);
3085
3086 HRESULT OnBeforeStateImageChange(
3087 [in] IShellItem *psi);
3088
3089 HRESULT OnGetDefaultIconIndex(
3090 [in] IShellItem *psi,
3091 [out] int *piDefaultIcon,
3092 [out] int *piOpenIcon);
3093 }
3094
3095 /*****************************************************************************
3096 * INameSpaceTreeControlCustomDraw interface
3097 */
3098 [
3099 object,
3100 uuid(2D3BA758-33EE-42D5-BB7B-5F3431D86C78),
3101 local
3102 ]
3103
3104 interface INameSpaceTreeControlCustomDraw : IUnknown
3105 {
3106 typedef struct NSTCCUSTOMDRAW
3107 {
3108 IShellItem *psi;
3109 UINT uItemState;
3110 NSTCITEMSTATE nstcis;
3111 LPCWSTR pszText;
3112 int iImage;
3113 HIMAGELIST himl;
3114 int iLevel;
3115 int iIndent;
3116 } NSTCCUSTOMDRAW;
3117
3118 HRESULT PrePaint(
3119 [in] HDC hdc,
3120 [in] RECT *prc,
3121 [out] LRESULT *plres);
3122
3123 HRESULT PostPaint(
3124 [in] HDC hdc,
3125 [in] RECT *prc);
3126
3127 HRESULT ItemPrePaint(
3128 [in] HDC hdc,
3129 [in] RECT *prc,
3130 [in, out] COLORREF *pclrText,
3131 [in, out] COLORREF *pclrTextBk,
3132 [out] LRESULT *plres);
3133
3134 HRESULT ItemPostPaint(
3135 [in] HDC hdc,
3136 [in] RECT *prc,
3137 [in] NSTCCUSTOMDRAW *pnstccdItem);
3138 }
3139
3140 /*****************************************************************************
3141 * INameSpaceTreeControlDropHandler interface
3142 */
3143 [
3144 object,
3145 uuid(F9C665D6-C2F2-4C19-BF33-8322D7352F51),
3146 local
3147 ]
3148 interface INameSpaceTreeControlDropHandler : IUnknown
3149 {
3150 HRESULT OnDragEnter(
3151 [in, unique] IShellItem *psiOver,
3152 [in] IShellItemArray *psiaData,
3153 [in] BOOL fOutsideSource,
3154 [in] DWORD grfKeyState,
3155 [in, out] DWORD *pdwEffect);
3156
3157 HRESULT OnDragOver(
3158 [in, unique] IShellItem *psiOver,
3159 [in] IShellItemArray *psiaData,
3160 [in] DWORD grfKeyState,
3161 [in, out] DWORD *pdwEffect);
3162
3163 HRESULT OnDragPosition(
3164 [in, unique] IShellItem *psiOver,
3165 [in] IShellItemArray *psiaData,
3166 [in] int iNewPosition,
3167 [in] int iOldPosition);
3168
3169 HRESULT OnDrop(
3170 [in, unique] IShellItem *psiOver,
3171 [in] IShellItemArray *psiaData,
3172 [in] int iPosition,
3173 [in] DWORD grfKeyState,
3174 [in, out] DWORD *pdwEffect);
3175
3176 HRESULT OnDropPosition(
3177 [in, unique] IShellItem *psiOver,
3178 [in] IShellItemArray *psiaData,
3179 [in] int iNewPosition,
3180 [in] int iOldPosition);
3181
3182 HRESULT OnDragLeave(
3183 [in, unique] IShellItem *psiOver);
3184 }
3185 cpp_quote("#define NSTCDHPOS_ONTOP -1")
3186
3187 interface IFileDialog;
3188
3189 typedef [v1_enum] enum FDE_OVERWRITE_RESPONSE
3190 {
3191 FDEOR_DEFAULT = 0,
3192 FDEOR_ACCEPT = 1,
3193 FDEOR_REFUSE = 2
3194 } FDE_OVERWRITE_RESPONSE;
3195
3196 typedef [v1_enum] enum FDE_SHAREVIOLATION_RESPONSE
3197 {
3198 FDESVR_DEFAULT = 0,
3199 FDESVR_ACCEPT = 1,
3200 FDESVR_REFUSE = 2
3201 } FDE_SHAREVIOLATION_RESPONSE;
3202
3203 /*****************************************************************************
3204 * IFileDialogEvents interface
3205 */
3206 [
3207 object,
3208 uuid(973510DB-7D7F-452B-8975-74A85828D354),
3209 pointer_default(unique)
3210 ]
3211 interface IFileDialogEvents : IUnknown
3212 {
3213 HRESULT OnFileOk(
3214 [in] IFileDialog *pfd);
3215
3216 HRESULT OnFolderChanging(
3217 [in] IFileDialog *pfd,
3218 [in] IShellItem *psiFolder);
3219
3220 HRESULT OnFolderChange(
3221 [in] IFileDialog *pfd);
3222
3223 HRESULT OnSelectionChange(
3224 [in] IFileDialog *pfd);
3225
3226 HRESULT OnShareViolation(
3227 [in] IFileDialog *pfd,
3228 [in] IShellItem *psi,
3229 [out] FDE_SHAREVIOLATION_RESPONSE *pResponse);
3230
3231 HRESULT OnTypeChange(
3232 [in] IFileDialog *pfd);
3233
3234 HRESULT OnOverwrite(
3235 [in] IFileDialog *pfd,
3236 [in] IShellItem *psi,
3237 [out] FDE_OVERWRITE_RESPONSE *pResponse);
3238 }
3239
3240 /*****************************************************************************
3241 * IModalWindow interface
3242 */
3243 [
3244 object,
3245 uuid(B4DB1657-70D7-485E-8E3E-6FCB5A5C1802),
3246 pointer_default(unique)
3247 ]
3248 interface IModalWindow : IUnknown
3249 {
3250 [local]
3251 HRESULT Show(
3252 [in, unique, annotation("__in_opt")] HWND hwndOwner);
3253
3254 [call_as(Show)]
3255 HRESULT RemoteShow(
3256 [in, unique] HWND hwndOwner);
3257 }
3258
3259 typedef [v1_enum] enum FDAP
3260 {
3261 FDAP_BOTTOM = 0,
3262 FDAP_TOP = 1
3263 } FDAP;
3264
3265 /*****************************************************************************
3266 * IFileDialog interface
3267 */
3268 [
3269 object,
3270 uuid(42F85136-DB7E-439C-85F1-E4075D135FC8),
3271 pointer_default(unique)
3272 ]
3273 interface IFileDialog : IModalWindow
3274 {
3275 [v1_enum] enum _FILEOPENDIALOGOPTIONS
3276 {
3277 FOS_OVERWRITEPROMPT = 0x00000002,
3278 FOS_STRICTFILETYPES = 0x00000004,
3279 FOS_NOCHANGEDIR = 0x00000008,
3280 FOS_PICKFOLDERS = 0x00000020,
3281 FOS_FORCEFILESYSTEM = 0x00000040,
3282 FOS_ALLNONSTORAGEITEMS = 0x00000080,
3283 FOS_NOVALIDATE = 0x00000100,
3284 FOS_ALLOWMULTISELECT = 0x00000200,
3285 FOS_PATHMUSTEXIST = 0x00000800,
3286 FOS_FILEMUSTEXIST = 0x00001000,
3287 FOS_CREATEPROMPT = 0x00002000,
3288 FOS_SHAREAWARE = 0x00004000,
3289 FOS_NOREADONLYRETURN = 0x00008000,
3290 FOS_NOTESTFILECREATE = 0x00010000,
3291 FOS_HIDEMRUPLACES = 0x00020000,
3292 FOS_HIDEPINNEDPLACES = 0x00040000,
3293 FOS_NODEREFERENCELINKS = 0x00100000,
3294 FOS_DONTADDTORECENT = 0x02000000,
3295 FOS_FORCESHOWHIDDEN = 0x10000000,
3296 FOS_DEFAULTNOMINIMODE = 0x20000000,
3297 FOS_FORCEPREVIEWPANEON = 0x40000000
3298 };
3299 typedef DWORD FILEOPENDIALOGOPTIONS;
3300
3301 HRESULT SetFileTypes(
3302 [in] UINT cFileTypes,
3303 [in, size_is(cFileTypes)] const COMDLG_FILTERSPEC *rgFilterSpec);
3304
3305 HRESULT SetFileTypeIndex(
3306 [in] UINT iFileType);
3307
3308 HRESULT GetFileTypeIndex(
3309 [out] UINT *piFileType);
3310
3311 HRESULT Advise(
3312 [in] IFileDialogEvents *pfde,
3313 [out] DWORD *pdwCookie);
3314
3315 HRESULT Unadvise(
3316 [in] DWORD dwCookie);
3317
3318 HRESULT SetOptions(
3319 [in] FILEOPENDIALOGOPTIONS fos);
3320
3321 HRESULT GetOptions(
3322 [in] FILEOPENDIALOGOPTIONS *pfos);
3323
3324 HRESULT SetDefaultFolder(
3325 [in] IShellItem *psi);
3326
3327 HRESULT SetFolder(
3328 [in] IShellItem *psi);
3329
3330 HRESULT GetFolder(
3331 [out] IShellItem **ppsi);
3332
3333 HRESULT GetCurrentSelection(
3334 [out] IShellItem **ppsi);
3335
3336 HRESULT SetFileName(
3337 [in, string] LPCWSTR pszName);
3338
3339 HRESULT GetFileName(
3340 [out, string] LPWSTR *pszName);
3341
3342 HRESULT SetTitle(
3343 [in, string] LPCWSTR pszTitle);
3344
3345 HRESULT SetOkButtonLabel(
3346 [in, string] LPCWSTR pszText);
3347
3348 HRESULT SetFileNameLabel(
3349 [in, string] LPCWSTR pszLabel);
3350
3351 HRESULT GetResult(
3352 [out] IShellItem **ppsi);
3353
3354 HRESULT AddPlace(
3355 [in] IShellItem *psi,
3356 [in] FDAP fdap);
3357
3358 HRESULT SetDefaultExtension(
3359 [in, string] LPCWSTR pszDefaultExtension);
3360
3361 HRESULT Close(
3362 [in] HRESULT hr);
3363
3364 HRESULT SetClientGuid(
3365 [in] REFGUID guid);
3366
3367 HRESULT ClearClientData();
3368
3369 HRESULT SetFilter(
3370 [in] IShellItemFilter *pFilter);
3371 }
3372
3373 /*****************************************************************************
3374 * IFileDialog2 interface
3375 */
3376 [
3377 object,
3378 uuid(61744FC7-85B5-4791-A9B0-272276309B13),
3379 pointer_default(unique)
3380 ]
3381 interface IFileDialog2 : IFileDialog
3382 {
3383 HRESULT SetCancelButtonLabel(
3384 [in] LPCWSTR pszLabel);
3385
3386 HRESULT SetNavigationRoot(
3387 [in] IShellItem *psi);
3388 }
3389
3390 /*****************************************************************************
3391 * IFileOperationProgressSink interface
3392 */
3393 [
3394 object,
3395 uuid(04B0F1A7-9490-44BC-96E1-4296A31252E2),
3396 pointer_default(unique)
3397 ]
3398 interface IFileOperationProgressSink : IUnknown
3399 {
3400 HRESULT StartOperations();
3401
3402 HRESULT FinishOperations(
3403 [in] HRESULT hrResult);
3404
3405 HRESULT PreRenameItem(
3406 [in] DWORD dwFlags,
3407 [in] IShellItem *psiItem,
3408 [in, unique, string] LPCWSTR pszNewName);
3409
3410 HRESULT PostRenameItem(
3411 [in] DWORD dwFlags,
3412 [in] IShellItem *psiItem,
3413 [in, string] LPCWSTR pszNewName,
3414 [in] HRESULT hrRename,
3415 [in] IShellItem *psiNewlyCreated);
3416
3417 HRESULT PreMoveItem(
3418 [in] DWORD dwFlags,
3419 [in] IShellItem *psiItem,
3420 [in] IShellItem *psiDestinationFolder,
3421 [in, unique, string] LPCWSTR pszNewName);
3422
3423 HRESULT PostMoveItem(
3424 [in] DWORD dwFlags,
3425 [in] IShellItem *psiItem,
3426 [in] IShellItem *psiDestinationFolder,
3427 [in, unique, string] LPCWSTR pszNewName,
3428 [in] HRESULT hrMove,
3429 [in] IShellItem *psiNewlyCreated);
3430
3431 HRESULT PreCopyItem(
3432 [in] DWORD dwFlags,
3433 [in] IShellItem *psiItem,
3434 [in] IShellItem *psiDestinationFolder,
3435 [in, unique, string] LPCWSTR pszNewName);
3436
3437 HRESULT PostCopyItem(
3438 [in] DWORD dwFlags,
3439 [in] IShellItem *psiItem,
3440 [in] IShellItem *psiDestinationFolder,
3441 [in, unique, string] LPCWSTR pszNewName,
3442 [in] HRESULT hrCopy,
3443 [in] IShellItem *psiNewlyCreated);
3444
3445 HRESULT PreDeleteItem(
3446 [in] DWORD dwFlags,
3447 [in] IShellItem *psiItem);
3448
3449 HRESULT PostDeleteItem(
3450 [in] DWORD dwFlags,
3451 [in] IShellItem *psiItem,
3452 [in] HRESULT hrDelete,
3453 [in] IShellItem *psiNewlyCreated);
3454
3455 HRESULT PreNewItem(
3456 [in] DWORD dwFlags,
3457 [in] IShellItem *psiDestinationFolder,
3458 [in, unique, string] LPCWSTR pszNewName);
3459
3460 HRESULT PostNewItem(
3461 [in] DWORD dwFlags,
3462 [in] IShellItem *psiDestinationFolder,
3463 [in, unique, string] LPCWSTR pszNewName,
3464 [in, unique, string] LPCWSTR pszTemplateName,
3465 [in] DWORD dwFileAttributes,
3466 [in] HRESULT hrNew,
3467 [in] IShellItem *psiNewItem);
3468
3469 HRESULT UpdateProgress(
3470 [in] UINT iWorkTotal,
3471 [in] UINT iWorkSoFar);
3472
3473 HRESULT ResetTimer();
3474
3475 HRESULT PauseTimer();
3476
3477 HRESULT ResumeTimer();
3478 }
3479
3480 /*****************************************************************************
3481 * IFileSaveDialog interface
3482 */
3483 [
3484 object,
3485 uuid(84BCCD23-5FDE-4CDB-AEA4-AF64B83D78AB),
3486 pointer_default(unique)
3487 ]
3488 interface IFileSaveDialog : IFileDialog
3489 {
3490 HRESULT SetSaveAsItem(
3491 [in] IShellItem *psi);
3492
3493 HRESULT SetProperties(
3494 [in] IPropertyStore *pStore);
3495
3496 HRESULT SetCollectedProperties(
3497 [in] IPropertyDescriptionList *pList,
3498 [in] BOOL fAppendDefault);
3499
3500 HRESULT GetProperties(
3501 [in] IPropertyStore **ppStore);
3502
3503 HRESULT ApplyProperties(
3504 [in] IShellItem *psi,
3505 [in] IPropertyStore *pStore,
3506 [in, unique] HWND hwnd,
3507 [in, unique] IFileOperationProgressSink *pSink);
3508 }
3509
3510
3511 /*****************************************************************************
3512 * IFileOpenDialog interface
3513 */
3514 [
3515 object,
3516 uuid(D57C7288-D4AD-4768-BE02-9D969532D960),
3517 pointer_default(unique)
3518 ]
3519 interface IFileOpenDialog : IFileDialog
3520 {
3521 HRESULT GetResults(
3522 [out] IShellItemArray **ppenum);
3523
3524 HRESULT GetSelectedItems(
3525 [out] IShellItemArray **ppsai);
3526 }
3527
3528 typedef [v1_enum] enum CDCONTROLSTATEF
3529 {
3530 CDCS_INACTIVE = 0x0,
3531 CDCS_ENABLED = 0x1,
3532 CDCS_VISIBLE = 0x2,
3533 CDCS_ENABLEDVISIBLE = 0x3
3534 } CDCONTROLSTATEF;
3535 cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(CDCONTROLSTATEF)")
3536 /*****************************************************************************
3537 * IFileDialogCustomize interface
3538 */
3539 [
3540 object,
3541 uuid(E6FDD21A-163F-4975-9C8C-A69F1BA37034),
3542 pointer_default(unique)
3543 ]
3544 interface IFileDialogCustomize : IUnknown
3545 {
3546 HRESULT EnableOpenDropDown(
3547 [in] DWORD dwIDCtl);
3548
3549 HRESULT AddMenu(
3550 [in] DWORD dwIDCtl,
3551 [in, string] LPCWSTR pszLabel);
3552
3553 HRESULT AddPushButton(
3554 [in] DWORD dwIDCtl,
3555 [in, string] LPCWSTR pszLabel);
3556
3557 HRESULT AddComboBox(
3558 [in] DWORD dwIDCtl);
3559
3560 HRESULT AddRadioButtonList(
3561 [in] DWORD dwIDCtl);
3562
3563 HRESULT AddCheckButton(
3564 [in] DWORD dwIDCtl,
3565 [in, string] LPCWSTR pszLabel,
3566 [in] BOOL bChecked);
3567
3568 HRESULT AddEditBox(
3569 [in] DWORD dwIDCtl,
3570 [in, string] LPCWSTR pszText);
3571
3572 HRESULT AddSeparator(
3573 [in] DWORD dwIDCtl);
3574
3575 HRESULT AddText(
3576 [in] DWORD dwIDCtl,
3577 [in, string] LPCWSTR pszText);
3578
3579 HRESULT SetControlLabel(
3580 [in] DWORD dwIDCtl,
3581 [in, string] LPCWSTR pszLabel);
3582
3583 HRESULT GetControlState(
3584 [in] DWORD dwIDCtl,
3585 [out] CDCONTROLSTATEF *pdwState);
3586
3587 HRESULT SetControlState(
3588 [in] DWORD dwIDCtl,
3589 [in] CDCONTROLSTATEF dwState);
3590
3591 HRESULT GetEditBoxText(
3592 [in] DWORD dwIDCtl,
3593 [out, string] WCHAR **ppszText);
3594
3595 HRESULT SetEditBoxText(
3596 [in] DWORD dwIDCtl,
3597 [in, string] LPCWSTR pszText);
3598
3599 HRESULT GetCheckButtonState(
3600 [in] DWORD dwIDCtl,
3601 [out] BOOL *pbChecked);
3602
3603 HRESULT SetCheckButtonState(
3604 [in] DWORD dwIDCtl,
3605 [in] BOOL bChecked);
3606
3607 HRESULT AddControlItem(
3608 [in] DWORD dwIDCtl,
3609 [in] DWORD dwIDItem,
3610 [in] LPCWSTR pszLabel);
3611
3612 HRESULT RemoveControlItem(
3613 [in] DWORD dwIDCtl,
3614 [in] DWORD dwIDItem);
3615
3616 HRESULT RemoveAllControlItems(
3617 [in] DWORD dwIDCtl);
3618
3619 HRESULT GetControlItemState(
3620 [in] DWORD dwIDCtl,
3621 [in] DWORD dwIDItem,
3622 [out] CDCONTROLSTATEF *pdwState);
3623
3624 HRESULT SetControlItemState(
3625 [in] DWORD dwIDCtl,
3626 [in] DWORD dwIDItem,
3627 [in] CDCONTROLSTATEF dwState);
3628
3629 HRESULT GetSelectedControlItem(
3630 [in] DWORD dwIDCtl,
3631 [out] DWORD *pdwIDItem);
3632
3633 HRESULT SetSelectedControlItem(
3634 [in] DWORD dwIDCtl,
3635 [in] DWORD dwIDItem);
3636
3637 HRESULT StartVisualGroup(
3638 [in] DWORD dwIDCtl,
3639 [in, string] LPCWSTR pszLabel);
3640
3641 HRESULT EndVisualGroup();
3642
3643 HRESULT MakeProminent(
3644 [in] DWORD dwIDCtl);
3645
3646 HRESULT SetControlItemText(
3647 [in] DWORD dwIDCtl,
3648 [in] DWORD dwIDItem,
3649 [in, string] LPCWSTR pszLabel);
3650 }
3651
3652 /*****************************************************************************
3653 * IFileDialogControlEvents interface
3654 */
3655 [
3656 object,
3657 uuid(36116642-D713-4B97-9B83-7484A9D00433),
3658 pointer_default(unique)
3659 ]
3660 interface IFileDialogControlEvents : IUnknown
3661 {
3662 HRESULT OnItemSelected(
3663 [in] IFileDialogCustomize *pfdc,
3664 [in] DWORD dwIDCtl,
3665 [in] DWORD dwIDItem);
3666
3667 HRESULT OnButtonClicked(
3668 [in] IFileDialogCustomize *pfdc,
3669 [in] DWORD dwIDCtl);
3670
3671 HRESULT OnCheckButtonToggled(
3672 [in] IFileDialogCustomize *pfdc,
3673 [in] BOOL dwIDCtl,
3674 [in] BOOL bChecked);
3675
3676 HRESULT OnControlActivating(
3677 [in] IFileDialogCustomize *pfdc,
3678 [in] DWORD dwIDCtl);
3679 }
3680
3681 typedef [v1_enum] enum tagKF_CATEGORY
3682 {
3683 KF_CATEGORY_VIRTUAL = 0x00000001,
3684 KF_CATEGORY_FIXED = 0x00000002,
3685 KF_CATEGORY_COMMON = 0x00000003,
3686 KF_CATEGORY_PERUSER = 0x00000004
3687 } KF_CATEGORY;
3688
3689 typedef [v1_enum] enum tagKF_REDIRECTION_CAPABILITIES
3690 {
3691 KF_REDIRECTION_CAPABILITIES_ALLOW_ALL = 0x000000ff,
3692 KF_REDIRECTION_CAPABILITIES_REDIRECTABLE = 0x00000001,
3693 KF_REDIRECTION_CAPABILITIES_DENY_ALL = 0x000fff00,
3694 KF_REDIRECTION_CAPABILITIES_DENY_POLICY_REDIRECTED = 0x00000100,
3695 KF_REDIRECTION_CAPABILITIES_DENY_POLICY = 0x00000200,
3696 KF_REDIRECTION_CAPABILITIES_DENY_PERMISSIONS = 0x00000400
3697 } KF_REDIRECTION_CAPABILITIES;
3698
3699 typedef [v1_enum] enum tagKF_DEFINITION_FLAGS
3700 {
3701 KFDF_LOCAL_REDIRECT_ONLY = 0x00000002,
3702 KFDF_ROAMABLE = 0x00000004,
3703 KFDF_PRECREATE = 0x00000008,
3704 KFDF_STREAM = 0x00000010,
3705 KFDF_PUBLISHEXPANDEDPATH = 0x00000020
3706 } KF_DEFINITION_FLAGS;
3707
3708 typedef struct tagKNOWNFOLDER_DEFINITION
3709 {
3710 KF_CATEGORY category;
3711 LPWSTR pszName;
3712 LPWSTR pszDescription;
3713 KNOWNFOLDERID fidParent;
3714 LPWSTR pszRelativePath;
3715 LPWSTR pszParsingName;
3716 LPWSTR pszTooltip;
3717 LPWSTR pszLocalizedName;
3718 LPWSTR pszIcon;
3719 LPWSTR pszSecurity;
3720 DWORD dwAttributes;
3721 KF_DEFINITION_FLAGS kfdFlags;
3722 FOLDERTYPEID ftidType;
3723 } KNOWNFOLDER_DEFINITION;
3724
3725 [
3726 object,
3727 uuid(3aa7af7e-9b36-420C-a8e3-f77d4674a488),
3728 pointer_default(ref)
3729 ]
3730 interface IKnownFolder : IUnknown
3731 {
3732 HRESULT GetId(
3733 [out] KNOWNFOLDERID *pkfid);
3734
3735 HRESULT GetCategory(
3736 [out] KF_CATEGORY *pCategory);
3737
3738 HRESULT GetShellItem(
3739 [in] DWORD dwFlags,
3740 [in] REFIID riid,
3741 [out, iid_is(riid)] void **ppv);
3742
3743 HRESULT GetPath(
3744 [in] DWORD dwFlags,
3745 [out, string] LPWSTR *ppszPath);
3746
3747 HRESULT SetPath(
3748 [in] DWORD dwFlags,
3749 [in, string] LPCWSTR pszPath);
3750
3751 HRESULT GetIDList(
3752 [in] DWORD dwFlags,
3753 [out] PIDLIST_ABSOLUTE *ppidl);
3754
3755 HRESULT GetFolderType(
3756 [out] FOLDERTYPEID *pftid);
3757
3758 HRESULT GetRedirectionCapabilities(
3759 [out] KF_REDIRECTION_CAPABILITIES *pCapabilities);
3760
3761 HRESULT GetFolderDefinition(
3762 [out] KNOWNFOLDER_DEFINITION *pKFD);
3763 }
3764
3765 typedef [v1_enum] enum tagKF_REDIRECT_FLAGS
3766 {
3767 KF_REDIRECT_USER_EXCLUSIVE = 0x00000001,
3768 KF_REDIRECT_COPY_SOURCE_DACL = 0x00000002,
3769 KF_REDIRECT_OWNER_USER = 0x00000004,
3770 KF_REDIRECT_SET_OWNER_EXPLICIT = 0x00000008,
3771 KF_REDIRECT_CHECK_ONLY = 0x00000010,
3772 KF_REDIRECT_WITH_UI = 0x00000020,
3773 KF_REDIRECT_UNPIN = 0x00000040,
3774 KF_REDIRECT_PIN = 0x00000080,
3775 KF_REDIRECT_COPY_CONTENTS = 0x00000200,
3776 KF_REDIRECT_DEL_SOURCE_CONTENTS = 0x00000400,
3777 KF_REDIRECT_EXCLUDE_ALL_KNOWN_SUBFOLDERS = 0x00000800
3778 } KF_REDIRECT_FLAGS;
3779
3780 [
3781 object,
3782 uuid(8BE2D872-86AA-4d47-B776-32CCA40C7018),
3783 pointer_default(ref)
3784 ]
3785 interface IKnownFolderManager : IUnknown
3786 {
3787 typedef [v1_enum] enum tagFFFP_MODE
3788 {
3789 FFFP_EXACTMATCH,
3790 FFFP_NEARESTPARENTMATCH
3791 } FFFP_MODE;
3792
3793 HRESULT FolderIdFromCsidl(
3794 [in] int nCsidl,
3795 [out] KNOWNFOLDERID *pfid);
3796
3797 HRESULT FolderIdToCsidl(
3798 [in] REFKNOWNFOLDERID rfid,
3799 [out] int *pnCsidl);
3800
3801 HRESULT GetFolderIds(
3802 [out, size_is(, *pCount)] KNOWNFOLDERID **ppKFId,
3803 [in, out] UINT *pCount);
3804
3805 HRESULT GetFolder(
3806 [in] REFKNOWNFOLDERID rfid,
3807 [out] IKnownFolder **ppkf);
3808
3809 HRESULT GetFolderByName(
3810 [in, string] LPCWSTR pszCanonicalName,
3811 [out] IKnownFolder **ppkf);
3812
3813 HRESULT RegisterFolder(
3814 [in] REFKNOWNFOLDERID rfid,
3815 [in] KNOWNFOLDER_DEFINITION const *pKFD);
3816
3817 HRESULT UnregisterFolder(
3818 [in] REFKNOWNFOLDERID rfid);
3819
3820 HRESULT FindFolderFromPath(
3821 [in, string] LPCWSTR pszPath,
3822 [in] FFFP_MODE mode,
3823 [out] IKnownFolder **ppkf);
3824
3825 HRESULT FindFolderFromIDList(
3826 [in] PCIDLIST_ABSOLUTE pidl,
3827 [out] IKnownFolder **ppkf);
3828
3829 HRESULT Redirect(
3830 [in] REFKNOWNFOLDERID rfid,
3831 [in, unique] HWND hwnd,
3832 [in] KF_REDIRECT_FLAGS flags,
3833 [in, unique, string] LPCWSTR pszTargetPath,
3834 [in] UINT cFolders,
3835 [in, size_is(cFolders), unique] KNOWNFOLDERID const *pExclusion,
3836 [out, string] LPWSTR *ppszError);
3837 }
3838
3839 /* function for releasing structure returned from IKnownFolder::GetFolderDefinition */
3840 cpp_quote("static inline void FreeKnownFolderDefinitionFields(KNOWNFOLDER_DEFINITION *pKFD)")
3841 cpp_quote("{")
3842 cpp_quote(" CoTaskMemFree(pKFD->pszName);")
3843 cpp_quote(" CoTaskMemFree(pKFD->pszDescription);")
3844 cpp_quote(" CoTaskMemFree(pKFD->pszRelativePath);")
3845 cpp_quote(" CoTaskMemFree(pKFD->pszParsingName);")
3846 cpp_quote(" CoTaskMemFree(pKFD->pszTooltip);")
3847 cpp_quote(" CoTaskMemFree(pKFD->pszLocalizedName);")
3848 cpp_quote(" CoTaskMemFree(pKFD->pszIcon);")
3849 cpp_quote(" CoTaskMemFree(pKFD->pszSecurity);")
3850 cpp_quote("}")
3851
3852 typedef [v1_enum] enum ASSOCIATIONLEVEL {
3853 AL_MACHINE,
3854 AL_EFFECTIVE,
3855 AL_USER
3856 } ASSOCIATIONLEVEL;
3857
3858 typedef [v1_enum] enum ASSOCIATIONTYPE {
3859 AT_FILEEXTENSION,
3860 AT_URLPROTOCOL,
3861 AT_STARTMENUCLIENT,
3862 AT_MIMETYPE
3863 } ASSOCIATIONTYPE;
3864
3865 [
3866 object,
3867 uuid(4e530b0a-e611-4c77-a3ac-9031d022281b),
3868 pointer_default(unique)
3869 ]
3870 interface IApplicationAssociationRegistration : IUnknown
3871 {
3872 HRESULT QueryCurrentDefault(
3873 [in, string] LPCWSTR pszQuery,
3874 [in] ASSOCIATIONTYPE atQueryType,
3875 [in] ASSOCIATIONLEVEL alQueryLevel,
3876 [out, string] LPWSTR *ppszAssociation);
3877
3878 HRESULT QueryAppIsDefault(
3879 [in, string] LPCWSTR pszQuery,
3880 [in] ASSOCIATIONTYPE atQueryType,
3881 [in] ASSOCIATIONLEVEL alQueryLevel,
3882 [in, string] LPCWSTR pszAppRegistryName,
3883 [out] BOOL *pfDefault);
3884
3885 HRESULT QueryAppIsDefaultAll(
3886 [in] ASSOCIATIONLEVEL alQueryLevel,
3887 [in, string] LPCWSTR pszAppRegistryName,
3888 [out] BOOL* pfDefault);
3889
3890 HRESULT SetAppAsDefault(
3891 [in, string] LPCWSTR pszAppRegistryName,
3892 [in, string] LPCWSTR pszSet,
3893 [in] ASSOCIATIONTYPE atSetType);
3894
3895 HRESULT SetAppAsDefaultAll(
3896 [in, string] LPCWSTR pszAppRegistryName);
3897
3898 HRESULT ClearUserAssociations();
3899 }
3900
3901 [
3902 uuid(6332debf-87b5-4670-90c0-5e57b408a49e),
3903 object,
3904 pointer_default(unique)
3905 ]
3906 interface ICustomDestinationList : IUnknown
3907 {
3908 typedef [v1_enum] enum KNOWNDESTCATEGORY {
3909 KDC_FREQUENT = 1,
3910 KDC_RECENT
3911 } KNOWNDESTCATEGORY;
3912
3913 HRESULT SetAppID([in, string] LPCWSTR pszAppID);
3914
3915 HRESULT BeginList(
3916 [out] UINT *pcMinSlots,
3917 [in] REFIID riid,
3918 [out, iid_is(riid)] void **ppv);
3919
3920 HRESULT AppendCategory(
3921 [in, string] LPCWSTR pszCategory,
3922 [in] IObjectArray *poa);
3923
3924 HRESULT AppendKnownCategory([in] KNOWNDESTCATEGORY category);
3925 HRESULT AddUserTasks([in] IObjectArray *poa);
3926 HRESULT CommitList();
3927
3928 HRESULT GetRemovedDestinations(
3929 [in] REFIID riid,
3930 [out, iid_is(riid)] void **ppv);
3931
3932 HRESULT DeleteList([in, unique, string] LPCWSTR pszAppID);
3933 HRESULT AbortList();
3934 }
3935
3936 [
3937 uuid(ddefe873-6997-4e68-be26-39b633adbe12),
3938 object,
3939 pointer_default(unique)
3940 ]
3941 interface IQueryCancelAutoPlay : IUnknown
3942 {
3943 HRESULT AllowAutoPlay([in, string] LPCWSTR path,
3944 [in] DWORD content_type,
3945 [in, string] LPCWSTR label,
3946 [in] DWORD serial_number);
3947 }
3948
3949 [
3950 uuid(d594d0d8-8da7-457b-b3b4-ce5dbaac0b88),
3951 pointer_default(unique)
3952 ]
3953 interface ITransferAdviseSink : IUnknown
3954 {
3955 [v1_enum] enum _TRANSFER_ADVISE_STATE
3956 {
3957 TS_NONE = 0,
3958 TS_PERFORMING = 1,
3959 TS_PREPARING = 2,
3960 TS_INDETERMINATE = 4
3961 };
3962 typedef DWORD TRANSFER_ADVISE_STATE;
3963
3964 HRESULT UpdateProgress([in] ULONGLONG size_current,
3965 [in] ULONGLONG size_total,
3966 [in] INT files_current,
3967 [in] INT files_total,
3968 [in] INT folders_current,
3969 [in] INT folders_total);
3970 HRESULT UpdateTransferState([in] TRANSFER_ADVISE_STATE state);
3971 HRESULT ConfirmOverwrite([in] IShellItem *source,
3972 [in] IShellItem *dest_parent,
3973 [in, string] LPCWSTR name);
3974 HRESULT ConfirmEncryptLoss([in] IShellItem *source);
3975 HRESULT FileFailure([in] IShellItem *item,
3976 [in, unique, string] LPCWSTR itemname,
3977 [in] HRESULT hr,
3978 [in, out, unique, size_is(crename)] LPWSTR rename,
3979 [in] ULONG crename);
3980 HRESULT SubStreamFailure([in] IShellItem *item,
3981 [in, string] LPCWSTR stream,
3982 [in] HRESULT hr);
3983 HRESULT PropertyFailure([in] IShellItem *item,
3984 [in, unique] const PROPERTYKEY *key,
3985 [in] HRESULT hr);
3986 }
3987
3988 [v1_enum] enum _TRANSFER_SOURCE_FLAGS
3989 {
3990 TSF_NORMAL = 0,
3991 TSF_FAIL_EXIST = 0,
3992 TSF_RENAME_EXIST = 0x1,
3993 TSF_OVERWRITE_EXIST = 0x2,
3994 TSF_ALLOW_DECRYPTION = 0x4,
3995 TSF_NO_SECURITY = 0x8,
3996 TSF_COPY_CREATION_TIME = 0x10,
3997 TSF_COPY_WRITE_TIME = 0x20,
3998 TSF_USE_FULL_ACCESS = 0x40,
3999 TSF_DELETE_RECYCLE_IF_POSSIBLE = 0x80,
4000 TSF_COPY_HARD_LINK = 0x100,
4001 TSF_COPY_LOCALIZED_NAME = 0x200,
4002 TSF_MOVE_AS_COPY_DELETE = 0x400,
4003 TSF_SUSPEND_SHELLEVENTS = 0x800
4004 };
4005 typedef DWORD TRANSFER_SOURCE_FLAGS;
4006
4007 [
4008 uuid(00adb003-bde9-45c6-8e29-d09f9353e108),
4009 object,
4010 pointer_default(unique)
4011 ]
4012 interface ITransferSource : IUnknown
4013 {
4014 HRESULT Advise([in] ITransferAdviseSink *sink, [out] DWORD *cookie);
4015 HRESULT Unadvise([in] DWORD cookie);
4016 HRESULT SetProperties([in] IPropertyChangeArray *array);
4017 HRESULT OpenItem([in] IShellItem *item,
4018 [in] TRANSFER_SOURCE_FLAGS flags,
4019 [in] REFIID riid,
4020 [out, iid_is(riid)] void **ppv);
4021 HRESULT MoveItem([in] IShellItem *item,
4022 [in] IShellItem *parent_dest,
4023 [in, string] LPCWSTR name_dest,
4024 [in] TRANSFER_SOURCE_FLAGS flags,
4025 [out] IShellItem **newitem);
4026 HRESULT RecycleItem([in] IShellItem *source,
4027 [in] IShellItem *parent_dest,
4028 [in] TRANSFER_SOURCE_FLAGS flags,
4029 [out] IShellItem **new_dest);
4030 HRESULT RemoveItem([in] IShellItem *source, [in] TRANSFER_SOURCE_FLAGS flags);
4031 HRESULT RenameItem([in] IShellItem *source,
4032 [in, string] LPCWSTR newname,
4033 [in] TRANSFER_SOURCE_FLAGS flags,
4034 [out] IShellItem **new_dest);
4035 HRESULT LinkItem([in] IShellItem *source,
4036 [in] IShellItem *parent_dest,
4037 [in, unique, string] LPCWSTR new_name,
4038 [in] TRANSFER_SOURCE_FLAGS flags,
4039 [out] IShellItem **new_dest);
4040 HRESULT ApplyPropertiesToItem([in] IShellItem *source, [out] IShellItem **newitem);
4041 HRESULT GetDefaultDestinationName([in] IShellItem *source,
4042 [in] IShellItem *parent_dest,
4043 [out, string] LPWSTR *dest_name);
4044 HRESULT EnterFolder([in] IShellItem *child_folder);
4045 HRESULT LeaveFolder([in] IShellItem *child_folder);
4046 }
4047
4048 [
4049 uuid(48addd32-3ca5-4124-abe3-b5a72531b207),
4050 object,
4051 pointer_default(unique)
4052 ]
4053 interface ITransferDestination : IUnknown
4054 {
4055 HRESULT Advise([in] ITransferAdviseSink *sink, [out] DWORD *cookie);
4056 HRESULT Unadvise([in] DWORD cookie);
4057 HRESULT CreateItem([in, string] LPCWSTR name,
4058 [in] DWORD attr,
4059 [in] ULONGLONG size,
4060 [in] TRANSFER_SOURCE_FLAGS flags,
4061 [in] REFIID riid,
4062 [out, iid_is(riid)] void **ppv,
4063 [in] REFIID resources,
4064 [out, iid_is(riid)] void **presources);
4065 }
4066
4067 /*****************************************************************************
4068 * ShellObjects typelibrary
4069 */
4070 [
4071 uuid(50A7E9B1-70EF-11D1-B75A-00A0C90564FE),
4072 lcid(0x0000),
4073 version(1.0)
4074 ]
4075 library ShellObjects
4076 {
4077 [
4078 uuid(71F96385-DDD6-48D3-A0C1-AE06E8B055FB)
4079 ]
4080 coclass ExplorerBrowser
4081 {
4082 interface IExplorerBrowser;
4083 }
4084
4085 [
4086 uuid(DC1C5A9C-E88A-4DDE-A5A1-60F82A20AEF7)
4087 ]
4088 coclass FileOpenDialog
4089 {
4090 interface IFileOpenDialog;
4091 }
4092
4093 [
4094 uuid(C0B4E2F3-BA21-4773-8DBA-335EC946EB8B)
4095 ]
4096 coclass FileSaveDialog
4097 {
4098 interface IFileSaveDialog;
4099 }
4100
4101 [
4102 uuid(AE054212-3535-4430-83ED-D501AA6680E6)
4103 ]
4104 coclass NamespaceTreeControl
4105 {
4106 interface INameSpaceTreeControl2;
4107 }
4108
4109 [
4110 uuid(4df0c730-df9d-4ae3-9153-aa6b82e9795a)
4111 ]
4112 coclass KnownFolderManager
4113 {
4114 interface IKnownFolderManager;
4115 }
4116
4117 [
4118 uuid(591209c7-767b-42b2-9fba-44ee4615f2c7)
4119 ]
4120 coclass ApplicationAssociationRegistration
4121 {
4122 interface IApplicationAssociationRegistration;
4123 }
4124
4125 [
4126 uuid(00021401-0000-0000-c000-000000000046)
4127 ]
4128 coclass ShellLink
4129 {
4130 interface IShellLinkW;
4131 }
4132
4133 [
4134 uuid(56fdf344-fd6d-11d0-958a-006097c9a090)
4135 ]
4136 coclass TaskbarList
4137 {
4138 interface ITaskbarList4;
4139 }
4140
4141 [
4142 uuid(77f10cf0-3db5-4966-b520-b7c54fd35ed6)
4143 ]
4144 coclass DestinationList {
4145 interface ICustomDestinationList;
4146 }
4147
4148 [
4149 uuid(331f1768-05a9-4ddd-b86e-dae34ddc998a)
4150 ]
4151 coclass QueryCancelAutoPlay
4152 {
4153 interface IQueryCancelAutoPlay;
4154 }
4155
4156 [
4157 uuid(9ac9fbe1-e0a2-4ad6-b4ee-e212013ea917)
4158 ]
4159 coclass ShellItem {
4160 interface IShellItem2;
4161 }
4162 }
4163
4164 enum _OPPROGDLGF
4165 {
4166 OPPROGDLG_DEFAULT = 0,
4167 OPPROGDLG_ENABLEPAUSE = 0x80,
4168 OPPROGDLG_ALLOWUNDO = 0x100,
4169 OPPROGDLG_DONTDISPLAYSOURCEPATH = 0x200,
4170 OPPROGDLG_DONTDISPLAYDESTPATH = 0x400,
4171 OPPROGDLG_NOMULTIDAYESTIMATES = 0x800,
4172 OPPROGDLG_DONTDISPLAYLOCATIONS = 0x1000
4173 };
4174 typedef DWORD OPPROGDLGF;
4175
4176 enum _PDMODE
4177 {
4178 PDM_DEFAULT = 0,
4179 PDM_RUN = 0x1,
4180 PDM_PREFLIGHT = 0x2,
4181 PDM_UNDOING = 0x4,
4182 PDM_ERRORSBLOCKING = 0x8,
4183 PDM_INDETERMINATE = 0x10
4184 };
4185 typedef DWORD PDMODE;
4186
4187 typedef enum PDOPSTATUS
4188 {
4189 PDOPS_RUNNING = 1,
4190 PDOPS_PAUSED = 2,
4191 PDOPS_CANCELLED = 3,
4192 PDOPS_STOPPED = 4,
4193 PDOPS_ERRORS = 5
4194 } PDOPSTATUS;
4195
4196 typedef enum _SPACTION
4197 {
4198 SPACTION_NONE = 0,
4199 SPACTION_MOVING = 1,
4200 SPACTION_COPYING = 2,
4201 SPACTION_RECYCLING = 3,
4202 SPACTION_APPLYINGATTRIBS = 4,
4203 SPACTION_DOWNLOADING = 5,
4204 SPACTION_SEARCHING_INTERNET = 6,
4205 SPACTION_CALCULATING = 7,
4206 SPACTION_UPLOADING = 8,
4207 SPACTION_SEARCHING_FILES = 9,
4208 SPACTION_DELETING = 10,