X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FFeaturesPlugin%2FFeaturesPlugin_Revolution.cpp;h=d4005402a11e03423a98419ebc4fbf0666f77df6;hb=32dfd57e82f818f4e3e36c276d78a30bbc2d9f7d;hp=12e053e324da48bab8f9b41016bf42da0fe62b40;hpb=dd31f5aedab7f3bb833b97fae5f82b32a92f927c;p=modules%2Fshaper.git diff --git a/src/FeaturesPlugin/FeaturesPlugin_Revolution.cpp b/src/FeaturesPlugin/FeaturesPlugin_Revolution.cpp index 12e053e32..d4005402a 100644 --- a/src/FeaturesPlugin/FeaturesPlugin_Revolution.cpp +++ b/src/FeaturesPlugin/FeaturesPlugin_Revolution.cpp @@ -61,7 +61,8 @@ void FeaturesPlugin_Revolution::execute() int aResultIndex = 0; ListOfShape::const_iterator aBaseIt = aBaseShapesList.cbegin(); ListOfMakeShape::const_iterator anAlgoIt = aMakeShapesList.cbegin(); - for(; aBaseIt != aBaseShapesList.cend() && anAlgoIt != aMakeShapesList.cend(); ++aBaseIt, ++anAlgoIt) { + for(; aBaseIt != aBaseShapesList.cend() && anAlgoIt != aMakeShapesList.cend(); + ++aBaseIt, ++anAlgoIt) { storeResult(*aBaseIt, *anAlgoIt, aResultIndex++); } @@ -103,7 +104,7 @@ bool FeaturesPlugin_Revolution::makeRevolutions(ListOfShape& theBaseShapes, double aToAngle = 0.0; double aFromAngle = 0.0; - if(string(CREATION_METHOD())->value() == "ByAngles") { + if(string(CREATION_METHOD())->value() == CREATION_METHOD_BY_ANGLES()) { aToAngle = real(TO_ANGLE_ID())->value(); aFromAngle = real(FROM_ANGLE_ID())->value(); } else { @@ -115,7 +116,7 @@ bool FeaturesPlugin_Revolution::makeRevolutions(ListOfShape& theBaseShapes, GeomShapePtr aToShape; GeomShapePtr aFromShape; - if(string(CREATION_METHOD())->value() == "ByPlanesAndOffsets") { + if(string(CREATION_METHOD())->value() == CREATION_METHOD_BY_PLANES()) { aSelection = selection(TO_OBJECT_ID()); if(aSelection.get()) { aToShape = std::dynamic_pointer_cast(aSelection->value()); @@ -133,12 +134,14 @@ bool FeaturesPlugin_Revolution::makeRevolutions(ListOfShape& theBaseShapes, } // Generating result for each base shape. - for(ListOfShape::const_iterator anIter = theBaseShapes.cbegin(); anIter != theBaseShapes.cend(); anIter++) { + for(ListOfShape::const_iterator + anIter = theBaseShapes.cbegin(); anIter != theBaseShapes.cend(); anIter++) { GeomShapePtr aBaseShape = *anIter; - std::shared_ptr aRevolAlgo(new GeomAlgoAPI_Revolution(aBaseShape, anAxis, - aToShape, aToAngle, - aFromShape, aFromAngle)); + std::shared_ptr aRevolAlgo(new GeomAlgoAPI_Revolution( + aBaseShape, anAxis, + aToShape, aToAngle, + aFromShape, aFromAngle)); if(!isMakeShapeValid(aRevolAlgo)) { return false; }