Skip to content

Commit

Permalink
Minor improvement for issue #1228
Browse files Browse the repository at this point in the history
  • Loading branch information
joachimmarder committed Nov 29, 2023
1 parent aa21804 commit 111a4d8
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions Source/VirtualTrees.Header.pas
Original file line number Diff line number Diff line change
Expand Up @@ -4415,9 +4415,12 @@ procedure TVirtualTreeColumns.FixPositions;
Items[I].Position := Count -1;
LoopAgain := True;
end;
if (i < Count -1) and (Items[I].Position = Items[I+1].FPosition) then
if (i < Count -1) and (Items[I].Position = Items[I+1].FPosition) then
begin
Dec(Items[I].FPosition);
if Items[I].FPosition > 0 then
Dec(Items[I].FPosition)
else
Inc(Items[I].FPosition);
LoopAgain := True;
end;
end; // for
Expand Down

0 comments on commit 111a4d8

Please sign in to comment.