LCL/ShellTreeView: Fix incorrect behavior of TShellTreeView after propagating node renaming to the file system. Issue #39629.

This commit is contained in:
wp_xyz 2022-02-04 10:50:42 +01:00
parent 61ad4be039
commit 931246668e

View File

@ -439,17 +439,16 @@ end;
function TShellTreeNode.ShortFilename: String;
begin
Result := ExtractFileName(FFileInfo.Name);
if (Result = '') then Result := FFileInfo.Name;
Result := Text;
end;
function TShellTreeNode.FullFilename: String;
begin
if (FBasePath <> '') then
Result := AppendPathDelim(FBasePath) + FFileInfo.Name
Result := AppendPathDelim(FBasePath) + Text
else
//root nodes
Result := FFileInfo.Name;
Result := Text;
{$if defined(windows) and not defined(wince)}
if (Length(Result) = 2) and (Result[2] = DriveSeparator) then
Result := Result + PathDelim;