Module: wine Branch: master Commit: 32a4ac1629409031c91bdf162298a3cc4ae58ad4 URL: http://source.winehq.org/git/wine.git/?a=commit;h=32a4ac1629409031c91bdf1622...
Author: Ulrich Czekalla ulrich.czekalla@utoronto.ca Date: Wed Sep 24 14:21:47 2008 -0400
shell32: Revert c1f2824429286dd60fac723611b801e67eb745b1. It caused poor performance.
Patch c1f2824429286dd60fac723611b801e67eb745b1 causes poor performance when browsing a directory. In fact it has a side affect that when you browse the root folder off of My Computer it will enumerate not only the root's contents but each subfolder's contents as well in order to get a more likely correct value for SFGAO_HASSUBFOLDER.
---
dlls/shell32/shlfolder.c | 16 ---------------- 1 files changed, 0 insertions(+), 16 deletions(-)
diff --git a/dlls/shell32/shlfolder.c b/dlls/shell32/shlfolder.c index cff924f..19ab6e1 100644 --- a/dlls/shell32/shlfolder.c +++ b/dlls/shell32/shlfolder.c @@ -466,22 +466,6 @@ HRESULT SHELL32_GetItemAttributes (IShellFolder * psf, LPCITEMIDLIST pidl, LPDWO if (!_ILGetExtension(pidl, ext, MAX_PATH) || lstrcmpiA(ext, "lnk")) *pdwAttributes &= ~SFGAO_LINK; } - - if (SFGAO_HASSUBFOLDER & *pdwAttributes) - { - IShellFolder *psf2; - if (SUCCEEDED(IShellFolder_BindToObject(psf, pidl, 0, (REFIID)&IID_IShellFolder, (LPVOID *)&psf2))) - { - IEnumIDList *pEnumIL = NULL; - if (SUCCEEDED(IShellFolder_EnumObjects(psf2, 0, SHCONTF_FOLDERS, &pEnumIL))) - { - if (IEnumIDList_Skip(pEnumIL, 1) != S_OK) - *pdwAttributes &= ~SFGAO_HASSUBFOLDER; - IEnumIDList_Release(pEnumIL); - } - IShellFolder_Release(psf2); - } - } } else { *pdwAttributes &= SFGAO_HASSUBFOLDER|SFGAO_FOLDER|SFGAO_FILESYSANCESTOR|SFGAO_DROPTARGET|SFGAO_HASPROPSHEET|SFGAO_CANRENAME|SFGAO_CANLINK; }