mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-08 07:58:06 +02:00
LazUtils: implement DbgS() for TMaskOpCodes and TWindowsQuirks in Masks unit.
This commit is contained in:
parent
ddcf2d27db
commit
33df1460d5
@ -371,8 +371,44 @@ function MatchesWindowsMaskList(const FileName, Mask: String; Separator: Char;
|
||||
deprecated 'Use MatchesWindowsMaskList with other params.'; // in Lazarus 2.3, remove in 2.5.
|
||||
|
||||
|
||||
function DbgS(O: TMaskOpCodes): String ; overload;
|
||||
function DbgS(Q: TWindowsQuirks): String ; overload;
|
||||
|
||||
implementation
|
||||
|
||||
function DbgS(O: TMaskOpCodes): String ;
|
||||
var
|
||||
S: String;
|
||||
Op: TMaskOpcode;
|
||||
begin
|
||||
Result := '[';
|
||||
for Op in O do
|
||||
begin
|
||||
WriteStr(S, Op);
|
||||
Result := Result + S + ',';
|
||||
end;
|
||||
if (Result[Length(Result)] = ',') then
|
||||
System.Delete(Result, Length(Result), 1);
|
||||
Result := Result + ']';
|
||||
end;
|
||||
|
||||
function DbgS(Q: TWindowsQuirks): String ;
|
||||
var
|
||||
S: String;
|
||||
Quirk: TWindowsQuirk;
|
||||
begin
|
||||
Result := '[';
|
||||
for Quirk in Q do
|
||||
begin
|
||||
WriteStr(S, Quirk);
|
||||
Result := Result + S + ',';
|
||||
end;
|
||||
if (Result[Length(Result)] = ',') then
|
||||
System.Delete(Result, Length(Result), 1);
|
||||
Result := Result + ']';
|
||||
end;
|
||||
|
||||
|
||||
function EncodeDisableRange(Options: TMaskOptions): TMaskOpCodes;
|
||||
// Encode the Disable Range option from legacy TMaskOptions.
|
||||
begin
|
||||
|
Loading…
Reference in New Issue
Block a user