fix small but constant load on idle caused by several timers

This commit is contained in:
Basile Burg 2020-02-18 06:44:56 +01:00
parent 647aa115e8
commit 90eedf284a
2 changed files with 4 additions and 3 deletions

View File

@ -422,7 +422,7 @@ begin
fMsgColors[amkInf] := $FFD0A8;
fMsgColors[amkHint] := $C2FFC2;
updaterByLoopInterval := 12;
updaterByLoopInterval := 200;
fOptions := TMessagesOptions.Create(Self);
fOptions.assign(self);
fOptions.Name:= 'messageOptions';
@ -993,10 +993,11 @@ procedure TMessagesWidget.updateLoop;
begin
if fastDisplay then
begin
List.BeginUpdate;
clearOutOfRangeMessg;
scrollToBack;
List.Update;
filterMessages(fCtxt);
List.EndUpdate;
end;
end;

View File

@ -178,7 +178,7 @@ begin
fStdoutEx := TMemoryStream.Create;
fStderrEx := TMemoryStream.Create;
FTerminateChecker := TTimer.Create(nil);
FTerminateChecker.Interval := 50;
FTerminateChecker.Interval := 200;
fTerminateChecker.OnTimer := @checkTerminated;
fTerminateChecker.Enabled := false;
TAsyncProcess(self).OnTerminate := @internalDoOnTerminate;