diff --git a/components/tachart/tachartutils.pas b/components/tachart/tachartutils.pas index 81e8fea6a2..80c6fde629 100644 --- a/components/tachart/tachartutils.pas +++ b/components/tachart/tachartutils.pas @@ -109,7 +109,6 @@ procedure CalculateIntervals( AMin, AMax: Double; AxisScale: TAxisScale; out AStart, AStep: Double); function DoublePoint(const ACoord: TChartCoord): TDoublePoint; -function EqualPoints(const A, B: TPoint): Boolean; inline; procedure Exchange(var A, B: Integer); overload; procedure Exchange(var A, B: Double); overload; @@ -206,11 +205,6 @@ begin Result.Y := ACoord.y; end; -function EqualPoints(const A, B: TPoint): Boolean; -begin - Result := (A.X = B.X) and (A.Y = B.Y); -end; - procedure Exchange(var A, B: Integer); overload; var t: Integer; diff --git a/components/tachart/tagraph.pas b/components/tachart/tagraph.pas index 59ecf15010..960567dfe4 100644 --- a/components/tachart/tagraph.pas +++ b/components/tachart/tagraph.pas @@ -312,7 +312,7 @@ var implementation uses - Clipbrd, LCLProc, Math; + Clipbrd, LCLProc, GraphMath, Math; const MinDouble = -1.7e308; @@ -1280,7 +1280,7 @@ begin if FShowReticule and Series[i].GetNearestPoint(@PointDistX, pt, pointIndex, newRetPos, value) and - not EqualPoints(newRetPos, FReticulePos) and PtInRect(r, newRetPos) + (newRetPos <> FReticulePos) and PtInRect(r, newRetPos) then begin DoDrawReticule(i, pointIndex, newRetPos, value.X, value.Y); DrawReticule(Canvas, FReticulePos);