X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FFeaturesPlugin%2FFeaturesPlugin_MultiRotation.cpp;h=4e3d05ba23f41abe7458901cd29e9c10c768062e;hb=766ce5d72bbae841d6c042befdf95e7d945039e1;hp=1fb43b872ddbf0d637044f839517126340c6ec0d;hpb=380f01e1fce1a012267d604a1190d04bf4659447;p=modules%2Fshaper.git diff --git a/src/FeaturesPlugin/FeaturesPlugin_MultiRotation.cpp b/src/FeaturesPlugin/FeaturesPlugin_MultiRotation.cpp index 1fb43b872..4e3d05ba2 100644 --- a/src/FeaturesPlugin/FeaturesPlugin_MultiRotation.cpp +++ b/src/FeaturesPlugin/FeaturesPlugin_MultiRotation.cpp @@ -1,4 +1,4 @@ -// Copyright (C) 2017-2020 CEA/DEN, EDF R&D +// Copyright (C) 2017-2021 CEA/DEN, EDF R&D // // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public @@ -44,6 +44,7 @@ #include #include #include +#include #include #include @@ -166,8 +167,9 @@ void FeaturesPlugin_MultiRotation::performRotation1D() GeomAPI_ShapeHierarchy anObjects; std::list aParts; - if (!FeaturesPlugin_Tools::shapesFromSelectionList( - anObjectsSelList, isKeepSubShapes, anObjects, aParts)) + ResultPtr aTextureSource; + if (!FeaturesPlugin_Tools::shapesFromSelectionList + (anObjectsSelList, isKeepSubShapes, anObjects, aParts, aTextureSource)) return; // Parameters of rotation. @@ -222,8 +224,10 @@ void FeaturesPlugin_MultiRotation::performRotation1D() anObjects.topLevelObjects(aTopLevel); for (ListOfShape::iterator anIt = aTopLevel.begin(); anIt != aTopLevel.end(); ++anIt) { ResultBodyPtr aResultBody = document()->createBody(data(), aResultIndex); - FeaturesPlugin_Tools::loadModifiedShapes(aResultBody, anOriginalShapes, ListOfShape(), - aMakeShapeList, *anIt, "Rotated"); + ModelAPI_Tools::loadModifiedShapes(aResultBody, anOriginalShapes, ListOfShape(), + aMakeShapeList, *anIt, "Rotated"); + // Copy image data, if any + ModelAPI_Tools::copyImageAttribute(aTextureSource, aResultBody); setResult(aResultBody, aResultIndex++); }