diff options
author | Tomaž Vajngerl <quikee@gmail.com> | 2013-12-09 21:18:12 +0100 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2013-12-09 23:05:12 +0100 |
commit | ee545ea38e89da0ab12684a1121a38f4a0c7d867 (patch) | |
tree | 86de5498de1a1f7261d854a03bd2070145d738e8 /chart2/source/controller/dialogs/ObjectNameProvider.cxx | |
parent | Updated core (diff) | |
download | core-ee545ea38e89da0ab12684a1121a38f4a0c7d867.tar.gz core-ee545ea38e89da0ab12684a1121a38f4a0c7d867.zip |
Display correct equation with multiple trendlines in chart.
When there were multiple trendlines for one data series and one
was selected, always the equation and R^2 of the first trendline
was displayed in status bar.
Change-Id: I320261e129c51bbdd1228173ca2f1d8447fdcb89
Diffstat (limited to 'chart2/source/controller/dialogs/ObjectNameProvider.cxx')
-rw-r--r-- | chart2/source/controller/dialogs/ObjectNameProvider.cxx | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/chart2/source/controller/dialogs/ObjectNameProvider.cxx b/chart2/source/controller/dialogs/ObjectNameProvider.cxx index 81146d389259..648a6c7e7b98 100644 --- a/chart2/source/controller/dialogs/ObjectNameProvider.cxx +++ b/chart2/source/controller/dialogs/ObjectNameProvider.cxx @@ -552,9 +552,11 @@ OUString ObjectNameProvider::getHelpText( const OUString& rObjectCID, const Refe aRet = SCH_RESSTR( STR_OBJECT_CURVE_WITH_PARAMETERS ); Reference< chart2::XDataSeries > xSeries( ObjectIdentifier::getDataSeriesForCID( rObjectCID , xChartModel )); Reference< chart2::XRegressionCurveContainer > xCurveCnt( xSeries, uno::UNO_QUERY ); + if( xCurveCnt.is()) { - Reference< chart2::XRegressionCurve > xCurve( RegressionCurveHelper::getFirstCurveNotMeanValueLine( xCurveCnt )); + sal_Int32 nCurveIndex = ObjectIdentifier::getIndexFromParticleOrCID( rObjectCID ); + Reference< chart2::XRegressionCurve > xCurve( RegressionCurveHelper::getRegressionCurveAtIndex(xCurveCnt, nCurveIndex) ); if( xCurve.is()) { try |