IDE: rename unit: fix resource directive only if lfm exists

git-svn-id: trunk@36487 -
This commit is contained in:
mattias 2012-03-31 17:24:37 +00:00
parent 3e852e27be
commit 11f34a7ec5

View File

@ -6289,13 +6289,13 @@ begin
LFMCode:=CodeToolBoss.LoadFile(NewLFMFilename,true,false);
if LFMCode<>nil then
NewLFMFilename:=LFMCode.Filename;
end;
ConvTool:=TConvDelphiCodeTool.Create(NewSource);
try
if not ConvTool.RenameResourceDirectives then
debugln(['TMainIDE.DoRenameUnit WARNING: unable to rename resource directive in "',NewSource.Filename,'"']);
finally
ConvTool.Free;
ConvTool:=TConvDelphiCodeTool.Create(NewSource);
try
if not ConvTool.RenameResourceDirectives then
debugln(['TMainIDE.DoRenameUnit WARNING: unable to rename resource directive in "',NewSource.Filename,'"']);
finally
ConvTool.Free;
end;
end;
end;