From 82d08c59cc858b80df5e9ca6a690d5164ec8a088 Mon Sep 17 00:00:00 2001 From: nds Date: Fri, 22 Nov 2013 06:17:23 +0000 Subject: [PATCH] Fix for the #trefs 127: regression - modification mode deletes section when modify point coordinates in table --- src/HYDROCurveCreator/CurveCreator_Curve.cxx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/HYDROCurveCreator/CurveCreator_Curve.cxx b/src/HYDROCurveCreator/CurveCreator_Curve.cxx index a07b1316..8572a116 100644 --- a/src/HYDROCurveCreator/CurveCreator_Curve.cxx +++ b/src/HYDROCurveCreator/CurveCreator_Curve.cxx @@ -874,7 +874,8 @@ bool CurveCreator_Curve::setPointInternal( const CurveCreator::SectionsMap &theS for( ; aPntIt != aSectionPoints.end(); aPntIt++ ){ int anIPnt = (*aPntIt)->myID; CurveCreator::Coordinates aCoords = (*aPntIt)->myCoords; - aSection->myPoints.assign(aCoords.begin(), aCoords.end()); + for ( int i = 0; i < myDimension; i++) + aSection->myPoints.at(toICoord(anIPnt) + i) = aCoords[i]; } res = true; } @@ -905,7 +906,10 @@ bool CurveCreator_Curve::setPoint( const int theISection, aPoints.push_back( aPosPoint ); aSectionsMap[theISection] = aPoints; + int aSize1 = getNbPoints( theISection ); res = setPointInternal( aSectionsMap ); + int aSize2 = getNbPoints( theISection ); + finishOperation(); return res; -- 2.39.2