mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-29 13:30:37 +02:00
Converter: improve reporting missing units.
git-svn-id: trunk@29513 -
This commit is contained in:
parent
cd87a812cc
commit
2e2e795109
@ -390,6 +390,7 @@ begin
|
|||||||
Add('FastMM4');
|
Add('FastMM4');
|
||||||
Add('FastMM4Messages');
|
Add('FastMM4Messages');
|
||||||
Add('OpenGL');
|
Add('OpenGL');
|
||||||
|
CaseSensitive:=False;
|
||||||
Sorted:=True;
|
Sorted:=True;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
@ -199,6 +199,8 @@ var
|
|||||||
OldUnitName, OldInFilename: String;
|
OldUnitName, OldInFilename: String;
|
||||||
NewUnitName, NewInFilename: String;
|
NewUnitName, NewInFilename: String;
|
||||||
AFilename, s, slo: String;
|
AFilename, s, slo: String;
|
||||||
|
x: Integer;
|
||||||
|
OmitUnit: Boolean;
|
||||||
begin
|
begin
|
||||||
UsesNode:=UsesSectionNode;
|
UsesNode:=UsesSectionNode;
|
||||||
if UsesNode=nil then exit(true);
|
if UsesNode=nil then exit(true);
|
||||||
@ -221,8 +223,8 @@ begin
|
|||||||
if NewInFilename<>'' then
|
if NewInFilename<>'' then
|
||||||
s:=s+' in '''+NewInFilename+'''';
|
s:=s+' in '''+NewInFilename+'''';
|
||||||
if AFilename<>'' then begin // unit found
|
if AFilename<>'' then begin // unit found
|
||||||
if (NewUnitName<>OldUnitName) and
|
OmitUnit:=Settings.OmitProjUnits.Find(NewUnitName, x);
|
||||||
not AUnitUpdater.FindReplacement(NewUnitName, slo) then begin
|
if (NewUnitName<>OldUnitName) and not OmitUnit then begin
|
||||||
// Character case differs and it will not be replaced.
|
// Character case differs and it will not be replaced.
|
||||||
fUnitsToFixCase[OldUnitName]:=NewUnitName; // fix case
|
fUnitsToFixCase[OldUnitName]:=NewUnitName; // fix case
|
||||||
IDEMessagesWindow.AddMsg(Format(lisConvDelphiFixedUnitCase,
|
IDEMessagesWindow.AddMsg(Format(lisConvDelphiFixedUnitCase,
|
||||||
@ -231,7 +233,7 @@ begin
|
|||||||
// Report Windows specific units as missing if target is MultiPlatform,
|
// Report Windows specific units as missing if target is MultiPlatform,
|
||||||
// needed if work-platform is Windows (kind of a hack).
|
// needed if work-platform is Windows (kind of a hack).
|
||||||
slo:=LowerCase(NewUnitName); // 'variants' ?
|
slo:=LowerCase(NewUnitName); // 'variants' ?
|
||||||
if Settings.MultiPlatform and ((slo='windows') or (slo='shellapi')) then
|
if (Settings.MultiPlatform and ((slo='windows') or (slo='shellapi'))) or OmitUnit then
|
||||||
fMissingUnits.Add(s);
|
fMissingUnits.Add(s);
|
||||||
end
|
end
|
||||||
else begin
|
else begin
|
||||||
|
Loading…
Reference in New Issue
Block a user