Converter: add to project/package also files without path definition in the main source file

git-svn-id: trunk@41725 -
This commit is contained in:
juha 2013-06-16 12:15:39 +00:00
parent 2aa7ae79c9
commit 66f27316e6

View File

@ -1599,6 +1599,17 @@ begin
if Result=mrAbort then
exit;
end;
for i:=0 to NormalUnits.Count-1 do begin
CurFilename:=NormalUnits[i];
//AllPath:=CodeToolBoss.DirectoryCachePool.FindDiskFilename(
// fSettings.MainPath+CurFilename+'.pas', true);
AllPath:=FindDiskFileCaseInsensitive(fSettings.MainPath+CurFilename+'.pas');
if AllPath<>'' then begin
Result:=AddUnit(AllPath, ui);
if Result=mrAbort then
exit;
end;
end;
finally
AllPath:=fUnitSearchPaths.DelimitedText;
// Set unit and include paths for project
@ -1945,6 +1956,15 @@ begin
if Result=mrAbort then
exit;
end;
for i:=0 to NormalUnits.Count-1 do begin
CurFilename:=NormalUnits[i];
AllPath:=FindDiskFileCaseInsensitive(fSettings.MainPath+CurFilename+'.pas');
if AllPath<>'' then begin
Result:=AddUnit(AllPath);
if Result=mrAbort then
exit;
end;
end;
finally
AllPath:=LazPackage.SourceDirectories.CreateSearchPathFromAllFiles;
UselessPath:='.;'+VirtualDirectory+';'+VirtualTempDir+';'+LazPackage.Directory;