1/* 2 * Type definitions 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 22import "wtypes.idl"; 23 24cpp_quote("#include <pshpack1.h>") 25typedef struct 26{ 27 WORD cb; /* nr of bytes in this item */ 28 BYTE abID[1]; /* first byte in this item */ 29} SHITEMID, *LPSHITEMID; 30typedef const SHITEMID *LPCSHITEMID; 31 32typedef struct _ITEMIDLIST 33{ 34 SHITEMID mkid; /* first itemid in list */ 35} ITEMIDLIST; 36 37#ifndef UNALIGNED 38#define UNALIGNED 39#endif 40 41typedef ITEMIDLIST UNALIGNED *LPITEMIDLIST; 42typedef const ITEMIDLIST UNALIGNED *LPCITEMIDLIST; 43 44cpp_quote("#if defined(STRICT_TYPED_ITEMIDS) && defined(__cplusplus)") 45cpp_quote("typedef struct _ITEMIDLIST_RELATIVE : public ITEMIDLIST { } ITEMIDLIST_RELATIVE;") 46cpp_quote("typedef struct _ITEMIDLIST_ABSOLUTE : public ITEMIDLIST_RELATIVE { } ITEMIDLIST_ABSOLUTE;") 47cpp_quote("typedef struct _ITEMID_CHILD : public ITEMIDLIST_RELATIVE { } ITEMID_CHILD;") 48cpp_quote("#else") 49typedef ITEMIDLIST ITEMIDLIST_RELATIVE; 50typedef ITEMIDLIST ITEMIDLIST_ABSOLUTE; 51typedef ITEMIDLIST ITEMID_CHILD; 52cpp_quote("#endif") 53 54typedef ITEMIDLIST_RELATIVE *PIDLIST_RELATIVE; 55typedef ITEMIDLIST_RELATIVE UNALIGNED *PUIDLIST_RELATIVE; 56typedef const ITEMIDLIST_RELATIVE *PCIDLIST_RELATIVE; 57typedef const ITEMIDLIST_RELATIVE UNALIGNED *PCUIDLIST_RELATIVE; 58typedef const PCUIDLIST_RELATIVE *PCUIDLIST_RELATIVE_ARRAY; 59 60typedef ITEMIDLIST_ABSOLUTE *PIDLIST_ABSOLUTE; 61typedef ITEMIDLIST_ABSOLUTE UNALIGNED *PUIDLIST_ABSOLUTE; 62typedef const ITEMIDLIST_ABSOLUTE *PCIDLIST_ABSOLUTE; 63typedef const ITEMIDLIST_ABSOLUTE UNALIGNED *PCUIDLIST_ABSOLUTE; 64typedef const PCIDLIST_ABSOLUTE *PCIDLIST_ABSOLUTE_ARRAY; 65typedef const PCUIDLIST_ABSOLUTE *PCUIDLIST_ABSOLUTE_ARRAY; 66 67typedef ITEMID_CHILD *PITEMID_CHILD; 68typedef ITEMID_CHILD UNALIGNED *PUITEMID_CHILD; 69typedef const ITEMID_CHILD *PCITEMID_CHILD; 70typedef const ITEMID_CHILD UNALIGNED *PCUITEMID_CHILD; 71typedef const PCUITEMID_CHILD *PCUITEMID_CHILD_ARRAY; 72 73cpp_quote("#include <poppack.h>") 74 75#ifndef MAX_PATH 76#define MAX_PATH 260 77#endif 78 79cpp_quote("#if 0") 80typedef struct { int dummy; } WIN32_FIND_DATAA, WIN32_FIND_DATAW; 81cpp_quote("#endif") 82 83typedef enum tagSTRRET_TYPE 84{ 85 STRRET_WSTR = 0, 86 STRRET_OFFSET = 1, 87 STRRET_CSTR = 2 88} STRRET_TYPE; 89 90cpp_quote("#include <pshpack8.h>") 91typedef struct _STRRET 92{ 93 UINT uType; /* STRRET_xxx */ 94 [switch_type(UINT), switch_is(uType)] union 95 { 96 [case(STRRET_WSTR)][string] LPWSTR pOleStr; /* OLESTR that will be freed */ 97 [case(STRRET_OFFSET)] UINT uOffset; /* Offset into SHITEMID (ANSI) */ 98 [case(STRRET_CSTR)] char cStr[MAX_PATH]; /* ANSI Buffer */ 99 } DUMMYUNIONNAME; 100} STRRET, *LPSTRRET; 101cpp_quote("#include <poppack.h>") 102 103cpp_quote("#include <pshpack1.h>") 104typedef struct 105{ 106 int fmt; 107 int cxChar; 108 STRRET str; 109} SHELLDETAILS, *LPSHELLDETAILS; 110cpp_quote("#include <poppack.h>") 111 112typedef struct _COMDLG_FILTERSPEC 113{ 114 [string] LPCWSTR pszName; 115 [string] LPCWSTR pszSpec; 116} COMDLG_FILTERSPEC; 117 118typedef [v1_enum] enum tagSHCOLSTATE 119{ 120 SHCOLSTATE_DEFAULT = 0, 121 SHCOLSTATE_TYPE_STR, 122 SHCOLSTATE_TYPE_INT, 123 SHCOLSTATE_TYPE_DATE, 124 SHCOLSTATE_TYPEMASK = 0xf, 125 SHCOLSTATE_ONBYDEFAULT = 0x10, 126 SHCOLSTATE_SLOW = 0x20, 127 SHCOLSTATE_EXTENDED = 0x40, 128 SHCOLSTATE_SECONDARYUI = 0x80, 129 SHCOLSTATE_HIDDEN = 0x100, 130 SHCOLSTATE_PREFER_VARCMP = 0x200, 131 SHCOLSTATE_PREFER_FMTCMP = 0x400, 132 SHCOLSTATE_NOSORTBYFOLDERNESS = 0x800, 133 SHCOLSTATE_VIEWONLY = 0x10000, 134 SHCOLSTATE_BATCHREAD = 0x20000, 135 SHCOLSTATE_NO_GROUPBY = 0x40000, 136 SHCOLSTATE_FIXED_WIDTH = 0x1000, 137 SHCOLSTATE_NODPISCALE = 0x2000, 138 SHCOLSTATE_FIXED_RATIO = 0x4000, 139 SHCOLSTATE_DISPLAYMASK = 0xf000 140} SHCOLSTATE; 141 142typedef DWORD SHCOLSTATEF; 143 144typedef GUID KNOWNFOLDERID; 145 146cpp_quote("#if 0") 147typedef KNOWNFOLDERID *REFKNOWNFOLDERID; 148cpp_quote("#endif") 149 150cpp_quote("#ifdef __cplusplus") 151cpp_quote("#define REFKNOWNFOLDERID const KNOWNFOLDERID &") 152cpp_quote("#else") 153cpp_quote("#define REFKNOWNFOLDERID const KNOWNFOLDERID * __MIDL_CONST") 154cpp_quote("#endif") 155 156typedef GUID FOLDERTYPEID; 157 158cpp_quote("#if 0") 159typedef FOLDERTYPEID *REFFOLDERTYPEID; 160cpp_quote("#endif") 161 162cpp_quote("#ifdef __cplusplus") 163cpp_quote("#define REFFOLDERTYPEID const FOLDERTYPEID &") 164cpp_quote("#else") 165cpp_quote("#define REFFOLDERTYPEID const FOLDERTYPEID * __MIDL_CONST") 166cpp_quote("#endif") 167 168typedef [v1_enum] enum tagPERCEIVED { 169 PERCEIVED_TYPE_CUSTOM = -3, 170 PERCEIVED_TYPE_UNSPECIFIED = -2, 171 PERCEIVED_TYPE_FOLDER = -1, 172 PERCEIVED_TYPE_UNKNOWN = 0, 173 PERCEIVED_TYPE_TEXT = 1, 174 PERCEIVED_TYPE_IMAGE = 2, 175 PERCEIVED_TYPE_AUDIO = 3, 176 PERCEIVED_TYPE_VIDEO = 4, 177 PERCEIVED_TYPE_COMPRESSED = 5, 178 PERCEIVED_TYPE_DOCUMENT = 6, 179 PERCEIVED_TYPE_SYSTEM = 7, 180 PERCEIVED_TYPE_APPLICATION = 8, 181 PERCEIVED_TYPE_GAMEMEDIA = 9, 182 PERCEIVED_TYPE_CONTACTS = 10 183} PERCEIVED; 184 185cpp_quote("#define PERCEIVEDFLAG_UNDEFINED 0x0000") 186cpp_quote("#define PERCEIVEDFLAG_SOFTCODED 0x0001") 187cpp_quote("#define PERCEIVEDFLAG_HARDCODED 0x0002") 188cpp_quote("#define PERCEIVEDFLAG_NATIVESUPPORT 0x0004") 189cpp_quote("#define PERCEIVEDFLAG_GDIPLUS 0x0010") 190cpp_quote("#define PERCEIVEDFLAG_WMSDK 0x0020") 191cpp_quote("#define PERCEIVEDFLAG_ZIPFOLDER 0x0040") 192