mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-06-01 03:52:35 +02:00
Packager: remove obsolete PkgSaveFlagNames and PkgOpenFlagNames, use WriteStr
git-svn-id: trunk@33244 -
This commit is contained in:
parent
09c62e511b
commit
c2a767ce5f
@ -154,19 +154,6 @@ type
|
||||
var
|
||||
PkgBoss: TBasePkgManager;
|
||||
|
||||
const
|
||||
PkgSaveFlagNames: array[TPkgSaveFlag] of string = (
|
||||
'psfSaveAs'
|
||||
);
|
||||
|
||||
PkgOpenFlagNames: array[TPkgOpenFlag] of string = (
|
||||
'pofAddToRecent',
|
||||
'pofRevert',
|
||||
'pofConvertMacros',
|
||||
'pofMultiOpen',
|
||||
'pofDoNotOpenEditor'
|
||||
);
|
||||
|
||||
function PkgSaveFlagsToString(Flags: TPkgSaveFlags): string;
|
||||
function PkgOpenFlagsToString(Flags: TPkgOpenFlags): string;
|
||||
|
||||
@ -181,12 +168,15 @@ implementation
|
||||
function PkgSaveFlagsToString(Flags: TPkgSaveFlags): string;
|
||||
var
|
||||
f: TPkgSaveFlag;
|
||||
s: string;
|
||||
begin
|
||||
Result:='';
|
||||
for f:=Low(TPkgSaveFlag) to High(TPkgSaveFlag) do begin
|
||||
if not (f in Flags) then continue;
|
||||
if Result<>'' then Result:=Result+',';
|
||||
Result:=Result+PkgSaveFlagNames[f];
|
||||
WriteStr(s, f);
|
||||
if Result<>'' then
|
||||
Result:=Result+',';
|
||||
Result:=Result+s;
|
||||
end;
|
||||
Result:='['+Result+']';
|
||||
end;
|
||||
@ -194,12 +184,15 @@ end;
|
||||
function PkgOpenFlagsToString(Flags: TPkgOpenFlags): string;
|
||||
var
|
||||
f: TPkgOpenFlag;
|
||||
s: string;
|
||||
begin
|
||||
Result:='';
|
||||
for f:=Low(TPkgOpenFlag) to High(TPkgOpenFlag) do begin
|
||||
if not (f in Flags) then continue;
|
||||
if Result<>'' then Result:=Result+',';
|
||||
Result:=Result+PkgOpenFlagNames[f];
|
||||
WriteStr(s, f);
|
||||
if Result<>'' then
|
||||
Result:=Result+',';
|
||||
Result:=Result+s;
|
||||
end;
|
||||
Result:='['+Result+']';
|
||||
end;
|
||||
|
Loading…
Reference in New Issue
Block a user