55#define NONAMELESSUNION
65#define _WIN32_WINNT 0x0600
81#include "wine/unicode.h"
88#define UNIMPLEMENTED_FLAGS \
89(OFN_DONTADDTORECENT |\
90OFN_NODEREFERENCELINKS | OFN_NOREADONLYRETURN |\
114static HHOOK s_hFileDialogHook =
NULL;
115static LONG s_nFileDialogHookCount = 0;
117#define MAX_TRANSLATE 8
118static HWND s_ahwndTranslate[MAX_TRANSLATE] = {
NULL };
120static void FILEDLG95_AddRemoveTranslate(
HWND hwndOld,
HWND hwndNew)
123 for (
i = 0;
i < MAX_TRANSLATE; ++
i)
125 if (s_ahwndTranslate[
i] == hwndOld)
127 s_ahwndTranslate[
i] = hwndNew;
139 if (s_ahwndTranslate[
i] ==
NULL)
143 if (fodInfos ==
NULL)
147 if (hwndView == hwndFocus ||
IsChild(hwndView, hwndFocus))
149 IShellView_TranslateAccelerator(fodInfos->
Shell.FOIShellView, pMsg);
172 for (
i = 0;
i < MAX_TRANSLATE; ++
i)
174 if (FILEDLG95_DoTranslate(
i, hwndFocus, pMsg))
197#define ITEM_NOTFOUND -1
200#define WM_GETISHELLBROWSER WM_USER+7
202#define TBPLACES_CMDID_PLACE0 0xa064
203#define TBPLACES_CMDID_PLACE1 0xa065
204#define TBPLACES_CMDID_PLACE2 0xa066
205#define TBPLACES_CMDID_PLACE3 0xa067
206#define TBPLACES_CMDID_PLACE4 0xa068
214#define CBGetItemDataPtr(hwnd,iItemId) \
215 SendMessageW(hwnd, CB_GETITEMDATA, (WPARAM)(iItemId), 0)
221 {
'S',
'o',
'f',
't',
'w',
'a',
'r',
'e',
'\\',
'M',
'i',
'c',
'r',
'o',
's',
'o',
'f',
't',
'\\',
222 'W',
'i',
'n',
'd',
'o',
'w',
's',
'\\',
'C',
'u',
'r',
'r',
'e',
'n',
't',
'V',
'e',
'r',
's',
'i',
'o',
'n',
'\\',
223 'E',
'x',
'p',
'l',
'o',
'r',
'e',
'r',
'\\',
'C',
'o',
'm',
'D',
'l',
'g',
'3',
'2',
'\\',
224 'L',
'a',
's',
't',
'V',
'i',
's',
'i',
't',
'e',
'd',
'M',
'R',
'U',0};
227static const WCHAR filedlg_info_propnameW[] = {
'F',
'i',
'l',
'e',
'O',
'p',
'e',
'n',
'D',
'l',
'g',
'I',
'n',
'f',
'o',
's',0};
358 static const WCHAR noplacesbarW[] = {
'N',
'o',
'P',
'l',
'a',
'c',
'e',
's',
'B',
'a',
'r',0};
380 static const int default_places[] =
402 static const WCHAR placeW[] = {
'P',
'l',
'a',
'c',
'e',
'%',
'd',0};
413 WARN(
"Unrecognized special folder %u.\n",
value);
455 FIXME(
"Flags 0x%08x not yet implemented\n",
462 templateid = NEWFILEOPENV2ORD;
464 templateid = NEWFILEOPENORD;
561 info->defext = pszExt;
681 if (
ret &&
info->ofnInfos->lpstrFile &&
info->ofnInfos->lpstrFileTitle)
732 LPSHELLFOLDER psfDesktop;
739 IShellFolder_Release(psfDesktop);
743 IShellFolder_Release(psfDesktop);
770 lstrcatW(lpstrPathAndFile, lpstrFile);
776 lstrcpyW(lpstrPathAndFile+2, lpstrFile);
778 lstrcpyW(lpstrPathAndFile, lpstrFile);
783 lstrcpyW(lpstrPathAndFile, lpstrTemp);
794 UINT nStrCharCount = 0;
804 while ( nStrCharCount <= nStrLen )
806 if ( lpstrEdit[nStrCharCount]==
'"' )
809 while ((nStrCharCount <= nStrLen) && (lpstrEdit[nStrCharCount]!=
'"'))
811 (*lpstrFileList)[nFileIndex++] = lpstrEdit[nStrCharCount];
814 (*lpstrFileList)[nFileIndex++] = 0;
821 if ((nStrLen > 0) && (nFileIndex == 0) )
823 lstrcpyW(*lpstrFileList, lpstrEdit);
824 nFileIndex =
lstrlenW(lpstrEdit) + 1;
829 (*lpstrFileList)[nFileIndex++] =
'\0';
831 *sizeUsed = nFileIndex;
842 HWND hwndChild, hwndStc32;
843 RECT rectParent, rectChild, rectStc32;
852 RECT rectHelp, rectCancel;
877 rectParent.
bottom -= help_fixup;
900 if (hwndChild != hwndStc32)
906 if (hwndStc32 && rectChild.left > rectStc32.
right)
909 rectChild.left += rectParent.
right;
910 rectChild.left -= rectStc32.
right;
913 if (rectChild.top >= rectStc32.
bottom)
916 rectChild.top += rectParent.
bottom;
917 rectChild.top -= rectStc32.
bottom - rectStc32.
top;
920 SetWindowPos(hwndChild, 0, rectChild.left, rectChild.top,
930 if (hwndChild != hwndChildDlg)
938 rectChild.left += rectStc32.
left;
939 rectChild.top += rectStc32.
top;
941 SetWindowPos(hwndChild, 0, rectChild.left, rectChild.top,
964 chgy = rectChild.
bottom - ( rectStc32.
bottom - rectStc32.
top) - help_fixup;
974 chgy = rectChild.
bottom - help_fixup;
980 rectParent.
right - rectParent.
left + chgx,
981 rectParent.
bottom - rectParent.
top + chgy,
1064 temp.tmplate.dwExtendedStyle = 0;
1065 temp.tmplate.cdit = 0;
1068 temp.tmplate.cx = 0;
1069 temp.tmplate.cy = 0;
1092 TRACE(
"%p %d\n", hwndParentDlg, uCode);
1094 if (!fodInfos || !fodInfos->
DlgInfos.hwndCustomDlg)
1097 TRACE(
"CALL NOTIFY for %d\n", uCode);
1110 TRACE(
"RET NOTIFY retval %#lx\n", hook_result);
1121 TRACE(
"CDM_GETFILEPATH:\n");
1163 if(!fodInfos)
return FALSE;
1172 TRACE(
"CDM_GETFOLDERPATH:\n");
1192 TRACE(
"CDM_GETSPEC:\n");
1204 TRACE(
"CDM_SETCONTROLTEXT:\n");
1223 else retval =
FALSE;
1256 FIXME(
"message CDM_FIRST+%04x not implemented\n", uMsg -
CDM_FIRST);
1333 else if( rc.top > rcview.
bottom)
1344 rc.right - rc.left + chgx, rc.bottom - rc.top,
1361 else if( rc.left > rcview.
right)
1377 rc.right - rc.left + chgx, rc.bottom - rc.top,
1391 rc.right - rc.left + chgx,
1392 rc.bottom - rc.top + chgy,
1402 if(fodInfos->
DlgInfos.hwndCustomDlg &&
1410 if( rc.top > rcview.
bottom)
1415 rc.right - rc.left, rc.bottom - rc.top,
1418 else if( rc.left > rcview.
right)
1423 rc.right - rc.left, rc.bottom - rc.top,
1479 style &= ~WS_SIZEBOX;
1508 if( fodInfos->
DlgInfos.hwndCustomDlg)
1524 rcstc.left, rcstc.top, rcstc.right - rcstc.left, rcstc.bottom - rcstc.top,
1552 if (++s_nFileDialogHookCount == 1)
1557 FILEDLG95_AddRemoveTranslate(
NULL,
hwnd);
1600 FILEDLG95_AddRemoveTranslate(
hwnd,
NULL);
1601 if (--s_nFileDialogHookCount == 0)
1604 s_hFileDialogHook =
NULL;
1679 static const WCHAR szwSlash[] = {
'\\', 0 };
1680 static const WCHAR szwStar[] = {
'*',0 };
1705 TRACE(
"%p\n", fodInfos);
1714 if (win2000plus) win98plus =
TRUE;
1716 TRACE(
"Running on 2000+ %d, 98+ %d\n", win2000plus, win98plus);
1745 rectTB.
top = rectlook.
top-1;
1834 handledPath =
FALSE;
1863 TRACE(
"Value in Filename includes path, overriding InitialDir: %s, %s\n",
1905 TRACE(
"Value in InitDir is not an existing path, changed to (nil)\n");
1932 if (!win2000plus && fodInfos->
filename &&
1954 TRACE(
"Value in Filename includes path, overriding initdir: %s, %s\n",
1961 if (!handledPath && win2000plus) {
1977 if (win98plus && !handledPath && fodInfos->
filter && *fodInfos->
filter) {
1988 if(! *lpstrPos)
break;
1989 lpstrPos +=
lstrlenW(lpstrPos) + 1;
1992 if(! *lpstrPos)
break;
1998 lpstrPos +=
lstrlenW(lpstrPos) + 1;
2007 TRACE(
"No initial dir specified, but files of type %s found in current, so using it\n",
2016 if (!handledPath && (win2000plus || win98plus)) {
2034 }
else if (!handledPath) {
2096 if (fodInfos->
DlgInfos.hwndCustomDlg)
2127 RECT rectDlg, rectHelp, rectCancel;
2153 TRACE(
"dir=%s file=%s\n",
2173 IShellBrowser_BrowseObject(fodInfos->
Shell.FOIShellBrowser,pidlItemId, SBSP_ABSOLUTE);
2197 TRACE(
"%p, %p\n",
info->ShellInfos.hwndOwner, pidl);
2199 IShellBrowser_BrowseObject(
info->Shell.FOIShellBrowser, pidl, SBSP_ABSOLUTE);
2278 fodInfos->
DlgInfos.dwDlgProp &= ~FODPROP_USEVIEW;
2321 TRACE(
"canceled\n");
2330 TRACE(
"canceled\n");
2349 UINT nCount, nSizePath;
2370 LPWSTR lpstrTemp = lpstrFileList;
2372 for ( nCount = 0; nCount < nFileCount; nCount++ )
2379 WCHAR lpstrNotFound[100];
2380 WCHAR lpstrMsg[100];
2382 static const WCHAR nl[] = {
'\n',0};
2398 lpstrTemp +=
lstrlenW(lpstrTemp) + 1;
2403 nSizePath =
lstrlenW(lpstrPathSpec) + 1;
2409 FIXME(
"Components have to be separated by blanks\n");
2460 WCHAR mru_list[32], *cur_mru_slot;
2461 BOOL taken[25] = {0};
2462 DWORD mru_list_size =
sizeof(mru_list), key_type = -1,
i;
2463 HKEY hkey_tmp, *hkey;
2472 *stored_path =
'\0';
2476 WARN(
"Unable to create MRU key: %d\n",
ret);
2481 (
LPBYTE)mru_list, &mru_list_size);
2486 WARN(
"Error getting MRUList data: type: %d, ret: %d\n", key_type,
ret);
2491 for(cur_mru_slot = mru_list; *cur_mru_slot; ++cur_mru_slot){
2493 DWORD value_data_size =
sizeof(value_data);
2495 *value_name = *cur_mru_slot;
2498 &key_type, (
LPBYTE)value_data, &value_data_size);
2500 WARN(
"Error getting MRU slot data: type: %d, ret: %d\n", key_type,
ret);
2517 for(cur_mru_slot = mru_list; *cur_mru_slot; ++cur_mru_slot)
2518 taken[*cur_mru_slot -
'a'] =
TRUE;
2519 for(
i = 0;
i < 25; ++
i){
2526 return *cur_mru_slot;
2554 WCHAR *path_ends, *
final;
2568 final[final_len-1] =
'\0';
2571 final_len *
sizeof(
WCHAR));
2583 WCHAR old_mru_list[32], new_mru_list[32];
2584 WCHAR *old_mru_slot, *new_mru_slot = new_mru_list;
2585 DWORD mru_list_size =
sizeof(old_mru_list), key_type;
2588 (
LPBYTE)old_mru_list, &mru_list_size);
2591 new_mru_list[0] =
slot;
2592 new_mru_list[1] =
'\0';
2594 WARN(
"Error getting MRUList data: type: %d, ret: %d\n", key_type,
ret);
2601 *new_mru_slot++ =
slot;
2602 for(old_mru_slot = old_mru_list; *old_mru_slot; ++old_mru_slot){
2603 if(*old_mru_slot !=
slot)
2604 *new_mru_slot++ = *old_mru_slot;
2606 *new_mru_slot =
'\0';
2612 WARN(
"Error saving MRUList data: %d\n",
ret);
2641static const WCHAR s_subkey[] =
2643 'S',
'o',
'f',
't',
'w',
'a',
'r',
'e',
'\\',
'M',
'i',
'c',
'r',
'o',
's',
'o',
'f',
't',
'\\',
2644 'W',
'i',
'n',
'd',
'o',
'w',
's',
'\\',
'C',
'u',
'r',
'r',
'e',
'n',
't',
'V',
'e',
'r',
's',
2645 'i',
'o',
'n',
'\\',
'E',
'x',
'p',
'l',
'o',
'r',
'e',
'r',
'\\',
'C',
'o',
'm',
'D',
'l',
'g',
2646 '3',
'2',
'\\',
'O',
'p',
'e',
'n',
'S',
'a',
'v',
'e',
'M',
'R',
'U',0
2648static const WCHAR s_szAst[] = {
'*', 0 };
2669#define MRU_STRING 0x0000
2670#define MRU_BINARY 0x0001
2671#define MRU_CACHEWRITE 0x0002
2677static CREATEMRULISTW s_pCreateMRUListW =
NULL;
2681static ADDMRUSTRINGW s_pAddMRUStringW =
NULL;
2685static FINDMRUSTRINGW s_pFindMRUStringW =
NULL;
2689static ENUMMRULISTW s_pEnumMRUListW =
NULL;
2693static FREEMRULIST s_pFreeMRUList =
NULL;
2695static BOOL FILEDLG_InitMRUList(
void)
2709 if (!s_pCreateMRUListW ||
2710 !s_pAddMRUStringW ||
2711 !s_pFindMRUStringW ||
2724 static const WCHAR s_image_exts[][6] =
2729 {
'j',
'p',
'e',
'g',0 },
2731 {
'j',
'f',
'i',
'f',0 },
2735 {
't',
'i',
'f',
'f',0 }
2760 if (!defext || !*defext || !FILEDLG_InitMRUList())
2769 if (!
result && hOpenSaveMRT)
2775 mi.hKey = hOpenSaveMRT;
2776 mi.lpszSubKey = defext;
2778 hList = (*s_pCreateMRUListW)(&
mi);
2781 ret = (*s_pEnumMRUListW)(
hList, 0, szText,
sizeof(szText));
2787 (*s_pFreeMRUList)(
hList);
2793 if (stored_path[0] == 0)
2796 if (ExtIsPicture(defext))
2817 if (!defext || !*defext || !FILEDLG_InitMRUList())
2826 if (!
result && hOpenSaveMRT)
2832 mi.hKey = hOpenSaveMRT;
2833 mi.lpszSubKey = defext;
2835 hList = (*s_pCreateMRUListW)(&
mi);
2839 (*s_pFreeMRUList)(
hList);
2845 mi.hKey = hOpenSaveMRT;
2846 mi.lpszSubKey = s_szAst;
2848 hList = (*s_pCreateMRUListW)(&
mi);
2852 (*s_pFreeMRUList)(
hList);
2868 strMsgTitle[0] =
'\0';
2886 if (lpstrFilter != (
LPWSTR)
CB_ERR && lpstrFilter && *lpstrFilter)
2893 pchDot =
wcschr(lpstrFilter,
L'.');
2895 if (pchDot && pchDot[1] && !
wcschr(pchDot,
L'*') && !
wcschr(pchDot,
L'?'))
2896 the_ext =
StrDupW(pchDot + 1);
2899 *pchSemicolon =
L';';
2902 if (!the_ext && (!pchDot || pchDot[1]))
2917 LPWSTR the_ext = FILEDLG95_GetFallbackExtension(fodInfos, lpstrPathAndFile);
2919 if (the_ext && *the_ext &&
2929 lstrcatW(lpstrPathAndFile, the_ext);
2966 int nOpenAction = defAction;
2967 LPWSTR lpszTemp, lpszTemp1;
2969 static const WCHAR szwInvalid[] = {
'/',
':',
'<',
'>',
'|', 0};
2980 lpszTemp1 = lpszTemp = lpstrPathAndFile;
2983 LPSHELLFOLDER lpsfChild;
2994 lpszTemp = lpszTemp +
lstrlenW(lpwstrTemp);
2999 static const WCHAR wszWild[] = {
'*',
'?', 0 };
3007 lpszTemp1 = lpszTemp;
3012 if(
lstrlenW(lpwstrTemp)==2 && lpwstrTemp[1] ==
':' &&
3013 ((lpwstrTemp[0] >=
'a' && lpwstrTemp[0] <=
'z') ||
3014 (lpwstrTemp[0] >=
'A' && lpwstrTemp[0] <=
'Z')))
3024 if((
dwAttributes & (SFGAO_FOLDER | SFGAO_FILESYSANCESTOR)) == (SFGAO_FOLDER | SFGAO_FILESYSANCESTOR))
3026 if(
FAILED(IShellFolder_BindToObject(*ppsf, pidl, 0, &IID_IShellFolder, (
LPVOID*)&lpsfChild)))
3028 ERR(
"bind to failed\n");
3031 IShellFolder_Release(*ppsf);
3049 (lpwstrTemp[
lstrlenW(lpwstrTemp)-1] ==
'\\'))
3062 FILEDLG95_AddDotExtIfNeeded(fodInfos, lpstrPathAndFile);
3100 UINT nFileCount = 0;
3104 LPSHELLFOLDER lpsf =
NULL;
3125 TRACE(
"count=%u len=%u file=%s\n", nFileCount, sizeUsed,
debugstr_w(lpstrFileList));
3176 TRACE(
"end validate sf=%p\n", lpsf);
3199 TRACE(
"ONOPEN_BROWSE\n");
3202 if(
SUCCEEDED(IShellFolder_QueryInterface( lpsf, &IID_IPersistFolder2, (
LPVOID*)&ppf2)))
3205 IPersistFolder2_GetCurFolder(ppf2, &pidlCurrent);
3206 IPersistFolder2_Release(ppf2);
3209 if (
SUCCEEDED(IShellBrowser_BrowseObject(fodInfos->
Shell.FOIShellBrowser, pidlCurrent, SBSP_ABSOLUTE))
3218 if (fodInfos->
Shell.FOIShellView)
3219 IShellView_Refresh(fodInfos->
Shell.FOIShellView);
3251 FILEDLG95_AddDotExtIfNeeded(fodInfos, lpstrPathAndFile);
3263 static const WCHAR szwDot[] = {
'.',0};
3272 WCHAR* filterSearchIndex;
3279 filterSearchIndex =
wcschr(filterExt,
';');
3280 if (filterSearchIndex)
3282 filterSearchIndex[0] =
'\0';
3288 filterSearchIndex =
wcschr(filterExt,
'.');
3289 if (filterSearchIndex++ && !
wcschr(filterSearchIndex,
'*') && !
wcschr(filterSearchIndex,
'?'))
3291 lstrcpyW(filterExt, filterSearchIndex);
3310 lstrcatW(lpstrPathAndFile, szwDot);
3312 lstrcatW(lpstrPathAndFile, filterExt);
3336 WCHAR lpstrOverwrite[100];
3354 WCHAR lpstrCreate[100];
3414 tempFileA,
sizeof(tempFileA),
NULL,
NULL);
3446 FILEDLG95_MRU_save_ext(lpstrPathAndFile);
3472 if(lpsf) IShellFolder_Release(lpsf);
3523 if(
SUCCEEDED(IShellView_GetItemObject(fodInfos->
Shell.FOIShellView,
3528 CMINVOKECOMMANDINFO ci;
3529 ZeroMemory(&ci,
sizeof(CMINVOKECOMMANDINFO));
3530 ci.cbSize =
sizeof(CMINVOKECOMMANDINFO);
3534 IContextMenu_InvokeCommand(pcm, &ci);
3535 IContextMenu_Release(pcm);
3553 if(
SUCCEEDED(IShellBrowser_BrowseObject(fodInfos->
Shell.FOIShellBrowser,
3577 if (fodInfos->
Shell.FOIShellView)
3579 IShellView_DestroyViewWindow(fodInfos->
Shell.FOIShellView);
3580 IShellView_Release(fodInfos->
Shell.FOIShellView);
3582 if (fodInfos->
Shell.FOIShellFolder)
3583 IShellFolder_Release(fodInfos->
Shell.FOIShellFolder);
3584 IShellBrowser_Release(fodInfos->
Shell.FOIShellBrowser);
3585 if (fodInfos->
Shell.FOIDataObject)
3586 IDataObject_Release(fodInfos->
Shell.FOIDataObject);
3614 if (! *lpstrPos)
return E_FAIL;
3638 if(! *lpstrPos)
break;
3639 lpstrDisplay = lpstrPos;
3640 lpstrPos +=
lstrlenW(lpstrPos) + 1;
3649 lpstrPos +=
lstrlenW(lpstrPos) + 1;
3655 if (!*lpstrExt)
break;
3744 if (fodInfos->
Shell.FOIShellView)
3745 IShellView_Refresh(fodInfos->
Shell.FOIShellView);
3765 for(
i=0;
i<iCount;
i++)
3792 for(iPos = iCount-1;iPos>=0;iPos--)
3813 static const WCHAR wszRootedAtDesktop[] = {
'S',
'o',
'f',
't',
'w',
'a',
'r',
'e',
'\\',
3814 'M',
'i',
'c',
'r',
'o',
's',
'o',
'f',
't',
'\\',
'W',
'i',
'n',
'd',
'o',
'w',
's',
'\\',
3815 'C',
'u',
'r',
'r',
'e',
'n',
't',
'V',
'e',
'r',
's',
'i',
'o',
'n',
'\\',
3816 'E',
'x',
'p',
'l',
'o',
'r',
'e',
'r',
'\\',
'D',
'e',
's',
'k',
't',
'o',
'p',
'\\',
3817 'N',
'a',
'm',
'e',
'S',
'p',
'a',
'c',
'e',
'\\',
'{',
'9',
'D',
'2',
'0',
'A',
'A',
'E',
'8',
3818 '-',
'0',
'6',
'2',
'5',
'-',
'4',
'4',
'B',
'0',
'-',
'9',
'C',
'A',
'7',
'-',
3819 '7',
'1',
'8',
'8',
'9',
'C',
'2',
'2',
'5',
'4',
'D',
'9',
'}',0 };
3832 LPITEMIDLIST pidlDrives, pidlTmp, pidlTmp1, pidlAbsTmp;
3835 LookInInfos *liInfos = heap_alloc_zero(
sizeof(*liInfos));
3837 TRACE(
"%p\n", hwndCombo);
3867 if(
SUCCEEDED(IShellFolder_EnumObjects(psfRoot, hwndCombo, SHCONTF_FOLDERS, &lpeRoot)))
3869 while (
S_OK == IEnumIDList_Next(lpeRoot, 1, &pidlTmp,
NULL))
3879 if(
SUCCEEDED(IShellFolder_BindToObject(psfRoot, pidlTmp,
NULL, &IID_IShellFolder, (
LPVOID*)&psfDrives)))
3882 if(
SUCCEEDED(IShellFolder_EnumObjects(psfDrives, hwndCombo,SHCONTF_FOLDERS, &lpeDrives)))
3884 while (
S_OK == IEnumIDList_Next(lpeDrives, 1, &pidlTmp1,
NULL))
3886 pidlAbsTmp =
ILCombine(pidlTmp, pidlTmp1);
3891 IEnumIDList_Release(lpeDrives);
3893 IShellFolder_Release(psfDrives);
3900 IEnumIDList_Release(lpeRoot);
3902 IShellFolder_Release(psfRoot);
3926 UINT icon_width, icon_height;
3930 if(pDIStruct->
itemID == -1)
3948 0, &sfi,
sizeof (sfi), shgfi_flags );
3965 if(pDIStruct->
itemState & ODS_COMBOBOXEDIT)
3973 rectIcon.
left = pDIStruct->
rcItem.
left + 1 + icon_width/2 * iIndentation;
4010 TRACE(
"%p\n", fodInfos);
4028 if(
SUCCEEDED(IShellBrowser_BrowseObject(fodInfos->
Shell.FOIShellBrowser,
4056 TRACE(
"%p, %p, %d\n",
hwnd, pidl, iInsertId);
4064 tmpFolder = heap_alloc_zero(
sizeof(*tmpFolder));
4069 while ((pidlNext =
ILGetNext(pidlNext)))
4079 sfi.
dwAttributes = SFGAO_FILESYSANCESTOR | SFGAO_FILESYSTEM;