mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-12-08 23:27:26 +01:00
LCL/ShellCtrls: Undo r64821 #3ff38bdc82 for the ShellTreeView (does not display overlay icons; no speed advantage in contrast to ShellListView)
git-svn-id: trunk@64823 -
This commit is contained in:
parent
bdc78cd5af
commit
77c4956c67
@ -60,11 +60,9 @@ function GetShellIcon(const AFileName: WideString): TIcon;
|
||||
var
|
||||
FileInfo: TSHFileInfoW;
|
||||
imgHandle: DWORD_PTR;
|
||||
attr: LongInt;
|
||||
begin
|
||||
attr := FileGetAttr(AFileName);
|
||||
imgHandle := SHGetFileInfoW(PWideChar(AFileName), attr, FileInfo, SizeOf(FileInfo),
|
||||
SHGFI_ICON or SHGFI_SMALLICON or SHGFI_SYSICONINDEX or SHGFI_USEFILEATTRIBUTES);
|
||||
imgHandle := SHGetFileInfoW(PWideChar(AFileName), 0, FileInfo, SizeOf(FileInfo),
|
||||
SHGFI_ICON or SHGFI_SMALLICON or SHGFI_SYSICONINDEX);
|
||||
if imgHandle <> 0 then
|
||||
begin
|
||||
Result := TIcon.Create;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user