makefiles: Add support for a generic SOURCES variable.
[wine.git] / dlls / shell32 / shfldr.h
bloba92f31b5ccf0b4b0939ebbceb5bf363a2887e361
1 /*
2 * Virtual Folder
3 * common definitions
5 * Copyright 1997 Marcus Meissner
6 * Copyright 1998, 1999, 2002 Juergen Schmied
8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Lesser General Public
10 * License as published by the Free Software Foundation; either
11 * version 2.1 of the License, or (at your option) any later version.
13 * This library is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Lesser General Public License for more details.
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with this library; if not, write to the Free Software
20 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
23 #include "stgprop.h"
25 #define CHARS_IN_GUID 39
27 typedef struct {
28 const GUID *fmtid;
29 DWORD pid;
30 int colnameid;
31 int pcsFlags;
32 int fmt;
33 int cxChar;
34 } shvheader;
36 HRESULT SHELL32_GetColumnDetails(const shvheader *data, int column, SHELLDETAILS *details) DECLSPEC_HIDDEN;
37 HRESULT shellfolder_map_column_to_scid(const shvheader *data, UINT column, SHCOLUMNID *scid) DECLSPEC_HIDDEN;
39 #define GET_SHGDN_FOR(dwFlags) ((DWORD)dwFlags & (DWORD)0x0000FF00)
40 #define GET_SHGDN_RELATION(dwFlags) ((DWORD)dwFlags & (DWORD)0x000000FF)
42 BOOL SHELL32_GetCustomFolderAttribute (LPCITEMIDLIST pidl, LPCWSTR pwszHeading, LPCWSTR pwszAttribute, LPWSTR pwszValue, DWORD cchValue) DECLSPEC_HIDDEN;
44 LPCWSTR GetNextElementW (LPCWSTR pszNext, LPWSTR pszOut, DWORD dwOut) DECLSPEC_HIDDEN;
45 HRESULT SHELL32_ParseNextElement (IShellFolder2 * psf, HWND hwndOwner, LPBC pbc, LPITEMIDLIST * pidlInOut,
46 LPOLESTR szNext, DWORD * pEaten, DWORD * pdwAttributes) DECLSPEC_HIDDEN;
47 HRESULT SHELL32_GetItemAttributes (IShellFolder2 *folder, LPCITEMIDLIST pidl, DWORD *attributes) DECLSPEC_HIDDEN;
48 HRESULT SHELL32_GetDisplayNameOfChild (IShellFolder2 * psf, LPCITEMIDLIST pidl, DWORD dwFlags, LPWSTR szOut,
49 DWORD dwOutLen) DECLSPEC_HIDDEN;
51 HRESULT SHELL32_BindToChild (LPCITEMIDLIST pidlRoot,
52 LPCWSTR pathRoot, LPCITEMIDLIST pidlComplete, REFIID riid, LPVOID * ppvOut) DECLSPEC_HIDDEN;
54 HRESULT SHELL32_CompareIDs(IShellFolder2 *iface, LPARAM lParam, LPCITEMIDLIST pidl1, LPCITEMIDLIST pidl2) DECLSPEC_HIDDEN;
55 LPITEMIDLIST SHELL32_CreatePidlFromBindCtx(IBindCtx *pbc, LPCWSTR path) DECLSPEC_HIDDEN;
57 HRESULT SHELL32_CreateExtensionUIObject(IShellFolder2 *iface, LPCITEMIDLIST pidl, REFIID riid, LPVOID *ppvOut) DECLSPEC_HIDDEN;
59 static inline int SHELL32_GUIDToStringA (REFGUID guid, LPSTR str)
61 return sprintf(str, "{%08x-%04x-%04x-%02x%02x-%02x%02x%02x%02x%02x%02x}",
62 guid->Data1, guid->Data2, guid->Data3,
63 guid->Data4[0], guid->Data4[1], guid->Data4[2], guid->Data4[3],
64 guid->Data4[4], guid->Data4[5], guid->Data4[6], guid->Data4[7]);
67 static inline int SHELL32_GUIDToStringW (REFGUID guid, LPWSTR str)
69 static const WCHAR fmtW[] =
70 { '{','%','0','8','l','x','-','%','0','4','x','-','%','0','4','x','-',
71 '%','0','2','x','%','0','2','x','-',
72 '%','0','2','x','%','0','2','x','%','0','2','x','%','0','2','x',
73 '%','0','2','x','%','0','2','x','}',0 };
74 return sprintfW(str, fmtW,
75 guid->Data1, guid->Data2, guid->Data3,
76 guid->Data4[0], guid->Data4[1], guid->Data4[2], guid->Data4[3],
77 guid->Data4[4], guid->Data4[5], guid->Data4[6], guid->Data4[7]);
80 void SHELL_FS_ProcessDisplayFilename(LPWSTR szPath, DWORD dwFlags) DECLSPEC_HIDDEN;
81 BOOL SHELL_FS_HideExtension(LPCWSTR pwszPath) DECLSPEC_HIDDEN;
83 DEFINE_GUID( CLSID_UnixFolder, 0xcc702eb2, 0x7dc5, 0x11d9, 0xc6, 0x87, 0x00, 0x04, 0x23, 0x8a, 0x01, 0xcd );
84 DEFINE_GUID( CLSID_UnixDosFolder, 0x9d20aae8, 0x0625, 0x44b0, 0x9c, 0xa7, 0x71, 0x88, 0x9c, 0x22, 0x54, 0xd9 );