Skip to content

Commit 5ea2e40

Browse files
committed
Fixed draw buffer pause
The draw buffer now caches Home and Search pages as well.
1 parent 9f95e1f commit 5ea2e40

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

MainUI.pas

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3465,6 +3465,15 @@ procedure TUIForm.HomeDrawPaint(Sender: TObject);
34653465
ScrollPosition.PageSize := 0;
34663466
ScrollPosition.Max := MaxScroll - HomeDraw.Height;
34673467
end;
3468+
3469+
// Copy draw buffer
3470+
with TPaintBox(Sender).Canvas do
3471+
begin
3472+
LastDrawBuffer.Width := ClipRect.Width;
3473+
LastDrawBuffer.Height := ClipRect.Height;
3474+
3475+
LastDrawBuffer.Canvas.CopyRect(ClipRect, TPaintBox(Sender).Canvas, ClipRect);
3476+
end;
34683477
end;
34693478

34703479
procedure TUIForm.PopupGeneralInfo(Sender: TObject);
@@ -6655,6 +6664,15 @@ procedure TUIForm.SearchDrawPaint(Sender: TObject);
66556664
ScrollPosition.PageSize := 0;
66566665
ScrollPosition.Max := Y + ScrollPosition.Position;
66576666
end;
6667+
6668+
// Copy draw buffer
6669+
with TPaintBox(Sender).Canvas do
6670+
begin
6671+
LastDrawBuffer.Width := ClipRect.Width;
6672+
LastDrawBuffer.Height := ClipRect.Height;
6673+
6674+
LastDrawBuffer.Canvas.CopyRect(ClipRect, TPaintBox(Sender).Canvas, ClipRect);
6675+
end;
66586676
end;
66596677

66606678
procedure TUIForm.Search_ButtonClick(Sender: TObject);

0 commit comments

Comments
 (0)