From 600a86c6b87bd3ae2cab491bb52a8dd14ad6ae24 Mon Sep 17 00:00:00 2001 From: vsr Date: Tue, 2 Mar 2010 11:28:01 +0000 Subject: [PATCH] Fix problem with FitAll of Plot2d view if curves in the view contain no points or only one point: additional change - replace std::min(), std::max() by qMin(), qMax(). --- src/Plot2d/Plot2d_ViewFrame.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Plot2d/Plot2d_ViewFrame.cxx b/src/Plot2d/Plot2d_ViewFrame.cxx index f6d61c474..a6f439f23 100755 --- a/src/Plot2d/Plot2d_ViewFrame.cxx +++ b/src/Plot2d/Plot2d_ViewFrame.cxx @@ -844,10 +844,10 @@ void Plot2d_ViewFrame::getFitRangeByCurves(double& xMin, double& xMax, xMax = yMax = y2Max = -1e150; } empty = false; - xMin = std::min( xMin, it.value()->getMinX() ); - xMax = std::max( xMax, it.value()->getMaxX() ); - yMin = std::min( yMin, it.value()->getMinY() ); - yMax = std::max( yMax, it.value()->getMaxY() ); + xMin = qMin( xMin, it.value()->getMinX() ); + xMax = qMax( xMax, it.value()->getMaxX() ); + yMin = qMin( yMin, it.value()->getMinY() ); + yMax = qMax( yMax, it.value()->getMaxY() ); } } if ( xMin == xMax ) { -- 2.39.2