mirror of https://gitlab.com/basile.b/dexed.git
sxsyn, fix range comparison
This commit is contained in:
parent
2428994828
commit
846f86fb40
|
@ -169,15 +169,13 @@ end;
|
||||||
function TSynSxSynRange.Compare(range: TSynCustomHighlighterRange): integer;
|
function TSynSxSynRange.Compare(range: TSynCustomHighlighterRange): integer;
|
||||||
begin
|
begin
|
||||||
result := inherited Compare(range);
|
result := inherited Compare(range);
|
||||||
assert(range <> nil);
|
if (range is TSynSxSynRange) and (rangeKind = TSynSxSynRange(range).rangeKind) then
|
||||||
if not result.equals(0) then
|
result := 1;
|
||||||
exit;
|
|
||||||
if range is TSynSxSynRange then
|
|
||||||
result := integer(rangeKind = TSynSxSynRange(range).rangeKind);
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TSynSxSynRange.Clear;
|
procedure TSynSxSynRange.Clear;
|
||||||
begin
|
begin
|
||||||
|
inherited;
|
||||||
rangeKind := TRangeKind.rkNone;
|
rangeKind := TRangeKind.rkNone;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue