Permalink
Browse files

Wrap filtering grid data in BeginUpdate/EndUpdate, so it might get a …

  • Loading branch information...
ansgarbecker committed Dec 14, 2018
1 parent 76825bc commit 94ae69e7668905d4df48465cdbaa5439ef956a32
Showing with 2 additions and 0 deletions.
  1. +2 −0 source/main.pas
@@ -7551,6 +7551,7 @@ procedure TMainForm.ApplyVTFilter(FromTimer: Boolean);
editFilterVT.RightButton.ImageIndex := 150;
editFilterVT.Repaint;

VT.BeginUpdate;
while Assigned(Node) do begin
// Don't filter anything if the filter text is empty
match := rx.Expression = '';
@@ -7566,6 +7567,7 @@ procedure TMainForm.ApplyVTFilter(FromTimer: Boolean);
inc(VisibleCount);
Node := VT.GetNext(Node);
end;
VT.EndUpdate;
if rx.Expression <> '' then begin
lblFilterVTInfo.Caption := f_('%0:d out of %1:d matching. %2:d hidden.', [VisibleCount, VT.RootNodeCount, VT.RootNodeCount - VisibleCount]);
end else

0 comments on commit 94ae69e

Please sign in to comment.