| 1 | /* $Id: shell.h,v 1.1 1999-05-24 20:19:19 ktk Exp $ */
|
|---|
| 2 |
|
|---|
| 3 | /*
|
|---|
| 4 | * Shell Library definitions
|
|---|
| 5 | */
|
|---|
| 6 | #ifndef __WINE_SHELL_H
|
|---|
| 7 | #define __WINE_SHELL_H
|
|---|
| 8 |
|
|---|
| 9 | #include "windef.h"
|
|---|
| 10 |
|
|---|
| 11 |
|
|---|
| 12 | /****************************************************************************
|
|---|
| 13 | * shell 16
|
|---|
| 14 | */
|
|---|
| 15 | extern void SHELL_LoadRegistry(void);
|
|---|
| 16 | extern void SHELL_SaveRegistry(void);
|
|---|
| 17 | extern void SHELL_Init(void);
|
|---|
| 18 |
|
|---|
| 19 | /* global functions used from shell32 */
|
|---|
| 20 | extern HINSTANCE SHELL_FindExecutable(LPCSTR,LPCSTR ,LPSTR);
|
|---|
| 21 | extern HGLOBAL16 WINAPI InternalExtractIcon16(HINSTANCE16,LPCSTR,UINT16,WORD);
|
|---|
| 22 |
|
|---|
| 23 | /****************************************************************************
|
|---|
| 24 | * shell 32
|
|---|
| 25 | */
|
|---|
| 26 | /****************************************************************************
|
|---|
| 27 | * common return codes
|
|---|
| 28 | */
|
|---|
| 29 | #define SHELL_ERROR_SUCCESS 0L
|
|---|
| 30 | #define SHELL_ERROR_BADDB 1L
|
|---|
| 31 | #define SHELL_ERROR_BADKEY 2L
|
|---|
| 32 | #define SHELL_ERROR_CANTOPEN 3L
|
|---|
| 33 | #define SHELL_ERROR_CANTREAD 4L
|
|---|
| 34 | #define SHELL_ERROR_CANTWRITE 5L
|
|---|
| 35 | #define SHELL_ERROR_OUTOFMEMORY 6L
|
|---|
| 36 | #define SHELL_ERROR_INVALID_PARAMETER 7L
|
|---|
| 37 | #define SHELL_ERROR_ACCESS_DENIED 8L
|
|---|
| 38 |
|
|---|
| 39 | /****************************************************************************
|
|---|
| 40 | * common shell file structures
|
|---|
| 41 | */
|
|---|
| 42 | /******************************
|
|---|
| 43 | * DRAG&DROP API
|
|---|
| 44 | */
|
|---|
| 45 | typedef struct { /* structure for dropped files */
|
|---|
| 46 | WORD wSize;
|
|---|
| 47 | POINT16 ptMousePos;
|
|---|
| 48 | BOOL16 fInNonClientArea;
|
|---|
| 49 | /* memory block with filenames follows */
|
|---|
| 50 | } DROPFILESTRUCT16, *LPDROPFILESTRUCT16;
|
|---|
| 51 |
|
|---|
| 52 | typedef struct { /* structure for dropped files */
|
|---|
| 53 | DWORD lSize;
|
|---|
| 54 | POINT ptMousePos;
|
|---|
| 55 | BOOL fInNonClientArea;
|
|---|
| 56 | BOOL fWideChar;
|
|---|
| 57 | /* memory block with filenames follows */
|
|---|
| 58 | } DROPFILESTRUCT, *LPDROPFILESTRUCT;
|
|---|
| 59 |
|
|---|
| 60 |
|
|---|
| 61 | /****************************************************************************
|
|---|
| 62 | * SHITEMID, ITEMIDLIST, PIDL API
|
|---|
| 63 | */
|
|---|
| 64 | #include "pshpack1.h"
|
|---|
| 65 | typedef struct
|
|---|
| 66 | { WORD cb; /* nr of bytes in this item */
|
|---|
| 67 | BYTE abID[1];/* first byte in this item */
|
|---|
| 68 | } SHITEMID,*LPSHITEMID;
|
|---|
| 69 |
|
|---|
| 70 | typedef struct
|
|---|
| 71 | { SHITEMID mkid; /* first itemid in list */
|
|---|
| 72 | } ITEMIDLIST,*LPITEMIDLIST,*LPCITEMIDLIST;
|
|---|
| 73 | #include "poppack.h"
|
|---|
| 74 |
|
|---|
| 75 | DWORD WINAPI SHGetPathFromIDListA (LPCITEMIDLIST pidl,LPSTR pszPath);
|
|---|
| 76 | DWORD WINAPI SHGetPathFromIDListW (LPCITEMIDLIST pidl,LPWSTR pszPath);
|
|---|
| 77 | #define SHGetPathFromIDList WINELIB_NAME_AW(SHGetPathFromIDList)
|
|---|
| 78 |
|
|---|
| 79 |
|
|---|
| 80 |
|
|---|
| 81 | /****************************************************************************
|
|---|
| 82 | * SHChangeNotifyRegister API
|
|---|
| 83 | */
|
|---|
| 84 | typedef struct
|
|---|
| 85 | { LPITEMIDLIST pidl;
|
|---|
| 86 | DWORD unknown;
|
|---|
| 87 | } IDSTRUCT;
|
|---|
| 88 |
|
|---|
| 89 | DWORD WINAPI SHChangeNotifyRegister(HWND hwnd,LONG events1,LONG events2,DWORD msg,int count,IDSTRUCT *idlist);
|
|---|
| 90 | DWORD WINAPI SHChangeNotifyDeregister(LONG x1);
|
|---|
| 91 |
|
|---|
| 92 | /****************************************************************************
|
|---|
| 93 | * SHAddToRecentDocs API
|
|---|
| 94 | */
|
|---|
| 95 | #define SHARD_PIDL 0x00000001L
|
|---|
| 96 | #define SHARD_PATH 0x00000002L
|
|---|
| 97 |
|
|---|
| 98 | DWORD WINAPI SHAddToRecentDocs(UINT uFlags, LPCVOID pv);
|
|---|
| 99 |
|
|---|
| 100 | /****************************************************************************
|
|---|
| 101 | * SHGetSpecialFolderLocation API
|
|---|
| 102 | */
|
|---|
| 103 | HRESULT WINAPI SHGetSpecialFolderLocation(HWND, INT, LPITEMIDLIST *);
|
|---|
| 104 | /****************************************************************************
|
|---|
| 105 | * string and path functions
|
|---|
| 106 | */
|
|---|
| 107 | BOOL WINAPI PathIsRootA(LPCSTR x);
|
|---|
| 108 | BOOL WINAPI PathIsRootW(LPCWSTR x);
|
|---|
| 109 | #define PathIsRoot WINELIB_NAME_AW(PathIsRoot)
|
|---|
| 110 | BOOL WINAPI PathIsRootAW(LPCVOID x);
|
|---|
| 111 |
|
|---|
| 112 | LPSTR WINAPI PathAddBackslashA(LPSTR path);
|
|---|
| 113 | LPWSTR WINAPI PathAddBackslashW(LPWSTR path);
|
|---|
| 114 | #define PathAddBackslash WINELIB_NAME_AW(PathAddBackslash)
|
|---|
| 115 | LPVOID WINAPI PathAddBackslashAW(LPVOID path);
|
|---|
| 116 |
|
|---|
| 117 | BOOL WINAPI PathQualifyA(LPCSTR path);
|
|---|
| 118 | BOOL WINAPI PathQualifyW(LPCWSTR path);
|
|---|
| 119 | #define PathQualify WINELIB_NAME_AW(PathQualify)
|
|---|
| 120 | BOOL WINAPI PathQualifyAW(LPCVOID path);
|
|---|
| 121 |
|
|---|
| 122 | LPSTR WINAPI PathQuoteSpacesA(LPCSTR path);
|
|---|
| 123 | LPWSTR WINAPI PathQuoteSpacesW(LPCWSTR path);
|
|---|
| 124 | #define PathQuoteSpaces WINELIB_NAME_AW(PathQuoteSpaces)
|
|---|
| 125 | LPVOID WINAPI PathQuoteSpacesAW(LPCVOID path);
|
|---|
| 126 |
|
|---|
| 127 | LPSTR WINAPI PathCombineA(LPSTR szDest, LPCSTR lpszDir, LPCSTR lpszFile);
|
|---|
| 128 | LPWSTR WINAPI PathCombineW(LPWSTR szDest, LPCWSTR lpszDir, LPCWSTR lpszFile);
|
|---|
| 129 | #define PathCombine WINELIB_NAME_AW(PathCombine)
|
|---|
| 130 | LPVOID WINAPI PathCombineAW(LPVOID szDest, LPCVOID lpszDir, LPCVOID lpszFile);
|
|---|
| 131 |
|
|---|
| 132 | LPCSTR WINAPI PathFindExtensionA(LPCSTR path);
|
|---|
| 133 | LPCWSTR WINAPI PathFindExtensionW(LPCWSTR path);
|
|---|
| 134 | #define PathFindExtension WINELIB_NAME_AW(PathFindExtension)
|
|---|
| 135 | LPCVOID WINAPI PathFindExtensionAW(LPCVOID path);
|
|---|
| 136 |
|
|---|
| 137 | LPCSTR WINAPI PathGetExtensionA(LPCSTR path, DWORD y, DWORD x);
|
|---|
| 138 | LPCWSTR WINAPI PathGetExtensionW(LPCWSTR path, DWORD y, DWORD x);
|
|---|
| 139 | #define PathGetExtension WINELIB_NAME_AW(PathGetExtension)
|
|---|
| 140 | LPCVOID WINAPI PathGetExtensionAW(LPCVOID path, DWORD y, DWORD x);
|
|---|
| 141 |
|
|---|
| 142 | LPCSTR WINAPI PathFindFilenameA(LPCSTR path);
|
|---|
| 143 | LPCWSTR WINAPI PathFindFilenameW(LPCWSTR path);
|
|---|
| 144 | #define PathFindFilename WINELIB_NAME_AW(PathFindFilename)
|
|---|
| 145 | LPCVOID WINAPI PathFindFilenameAW(LPCVOID path);
|
|---|
| 146 |
|
|---|
| 147 | BOOL WINAPI PathMatchSpecA(LPCSTR x, LPCSTR y);
|
|---|
| 148 | BOOL WINAPI PathMatchSpecW(LPCWSTR x, LPCWSTR y);
|
|---|
| 149 | #define PathMatchSpec WINELIB_NAME_AW(PathMatchSpec)
|
|---|
| 150 | BOOL WINAPI PathMatchSpecAW(LPVOID x, LPVOID y);
|
|---|
| 151 |
|
|---|
| 152 | LPSTR WINAPI PathRemoveBlanksA(LPSTR str);
|
|---|
| 153 | LPWSTR WINAPI PathRemoveBlanksW(LPWSTR str);
|
|---|
| 154 | #define PathRemoveBlanks WINELIB_NAME_AW(PathRemoveBlanks)
|
|---|
| 155 | LPVOID WINAPI PathRemoveBlanksAW(LPVOID str);
|
|---|
| 156 |
|
|---|
| 157 | BOOL WINAPI PathIsRelativeA(LPCSTR str);
|
|---|
| 158 | BOOL WINAPI PathIsRelativeW(LPCWSTR str);
|
|---|
| 159 | #define PathIsRelative WINELIB_NAME_AW(PathIsRelative)
|
|---|
| 160 | BOOL WINAPI PathIsRelativeAW(LPCVOID str);
|
|---|
| 161 |
|
|---|
| 162 | BOOL WINAPI PathIsUNCA(LPCSTR str);
|
|---|
| 163 | BOOL WINAPI PathIsUNCW(LPCWSTR str);
|
|---|
| 164 | #define PathIsUNC WINELIB_NAME_AW(PathIsUNC)
|
|---|
| 165 | BOOL WINAPI PathIsUNCAW(LPCVOID str);
|
|---|
| 166 |
|
|---|
| 167 | BOOL WINAPI PathFindOnPathA(LPSTR sFile, LPCSTR sOtherDirs);
|
|---|
| 168 | BOOL WINAPI PathFindOnPathW(LPWSTR sFile, LPCWSTR sOtherDirs);
|
|---|
| 169 | #define PathFindOnPath WINELIB_NAME_AW(PathFindOnPath)
|
|---|
| 170 | BOOL WINAPI PathFindOnPathAW(LPVOID sFile, LPCVOID sOtherDirs);
|
|---|
| 171 |
|
|---|
| 172 | LPSTR WINAPI StrFormatByteSizeA ( DWORD dw, LPSTR pszBuf, UINT cchBuf );
|
|---|
| 173 | LPWSTR WINAPI StrFormatByteSizeW ( DWORD dw, LPWSTR pszBuf, UINT cchBuf );
|
|---|
| 174 | #define StrFormatByteSize WINELIB_NAME_AW(StrFormatByteSize)
|
|---|
| 175 |
|
|---|
| 176 | /****************************************************************************
|
|---|
| 177 | * other functions
|
|---|
| 178 | */
|
|---|
| 179 |
|
|---|
| 180 | LPVOID WINAPI SHAlloc(DWORD len);
|
|---|
| 181 | DWORD WINAPI SHFree(LPVOID x);
|
|---|
| 182 |
|
|---|
| 183 | #define CSIDL_DESKTOP 0x0000
|
|---|
| 184 | #define CSIDL_PROGRAMS 0x0002
|
|---|
| 185 | #define CSIDL_CONTROLS 0x0003
|
|---|
| 186 | #define CSIDL_PRINTERS 0x0004
|
|---|
| 187 | #define CSIDL_PERSONAL 0x0005
|
|---|
| 188 | #define CSIDL_FAVORITES 0x0006
|
|---|
| 189 | #define CSIDL_STARTUP 0x0007
|
|---|
| 190 | #define CSIDL_RECENT 0x0008
|
|---|
| 191 | #define CSIDL_SENDTO 0x0009
|
|---|
| 192 | #define CSIDL_BITBUCKET 0x000a
|
|---|
| 193 | #define CSIDL_STARTMENU 0x000b
|
|---|
| 194 | #define CSIDL_DESKTOPDIRECTORY 0x0010
|
|---|
| 195 | #define CSIDL_DRIVES 0x0011
|
|---|
| 196 | #define CSIDL_NETWORK 0x0012
|
|---|
| 197 | #define CSIDL_NETHOOD 0x0013
|
|---|
| 198 | #define CSIDL_FONTS 0x0014
|
|---|
| 199 | #define CSIDL_TEMPLATES 0x0015
|
|---|
| 200 | #define CSIDL_COMMON_STARTMENU 0x0016
|
|---|
| 201 | #define CSIDL_COMMON_PROGRAMS 0X0017
|
|---|
| 202 | #define CSIDL_COMMON_STARTUP 0x0018
|
|---|
| 203 | #define CSIDL_COMMON_DESKTOPDIRECTORY 0x0019
|
|---|
| 204 | #define CSIDL_APPDATA 0x001a
|
|---|
| 205 | #define CSIDL_PRINTHOOD 0x001b
|
|---|
| 206 | #define CSIDL_ALTSTARTUP 0x001d
|
|---|
| 207 | #define CSIDL_COMMON_ALTSTARTUP 0x001e
|
|---|
| 208 | #define CSIDL_COMMON_FAVORITES 0x001f
|
|---|
| 209 | #define CSIDL_INTERNET_CACHE 0x0020
|
|---|
| 210 | #define CSIDL_COOKIES 0x0021
|
|---|
| 211 | #define CSIDL_HISTORY 0x0022
|
|---|
| 212 |
|
|---|
| 213 | #endif /* __WINE_SHELL_H */
|
|---|