From f6fc50d43cc646e6009d8ca2845df3468c83d397 Mon Sep 17 00:00:00 2001 From: wp Date: Tue, 16 Apr 2019 17:57:01 +0000 Subject: [PATCH] TAChart: Simplify calculation of TCustomChartSource.BasicExtent when XCount = 0. git-svn-id: trunk@60998 - --- components/tachart/tacustomsource.pas | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/tachart/tacustomsource.pas b/components/tachart/tacustomsource.pas index f8e13e5bcd..f37f762c25 100644 --- a/components/tachart/tacustomsource.pas +++ b/components/tachart/tacustomsource.pas @@ -828,8 +828,8 @@ begin for i:=0 to Count - 1 do UpdateMinMax(Item[i]^.X, FBasicExtent.a.X, FBasicExtent.b.X); end else begin - UpdateMinMax(0, FBasicExtent.a.X, FBasicExtent.b.X); - UpdateMinMax(Count-1, FBasicExtent.a.X, FBasicExtent.b.X); + FBasicExtent.a.X := 0; + FBasicExtent.b.X := Count - 1; end; if YCount > 0 then begin