From: Nicolas RECHATIN Date: Wed, 21 Jul 2021 13:54:19 +0000 (+0200) Subject: feature addVolume cleaned X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=6a1901531b0718122b8f8c203c4ba96ca4066209;p=modules%2Fshaper.git feature addVolume cleaned --- diff --git a/src/OperaPlugin/OperaPlugin_Volume.cpp b/src/OperaPlugin/OperaPlugin_Volume.cpp index ac2c3bfe2..c033b9302 100644 --- a/src/OperaPlugin/OperaPlugin_Volume.cpp +++ b/src/OperaPlugin/OperaPlugin_Volume.cpp @@ -16,7 +16,6 @@ // // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com // - #include #include @@ -51,34 +50,8 @@ void OperaPlugin_Volume::initAttributes() //================================================================================================= void OperaPlugin_Volume::execute() { - // Getting objects. - std::cout << "Before" << std::endl; - if (results().empty() || firstResult()->isDisabled()) { // just create result if not exists - ResultPtr aGroup = document()->createVolume(data()); - setResult(aGroup); - } - - std::cout << "After" << std::endl; -} - -//================================================================================================= -void OperaPlugin_Volume::loadNamingDS(std::shared_ptr theBoxAlgo, - std::shared_ptr theResultBox) -{ - // Load the result - theResultBox->store(theBoxAlgo->shape()); - - // Prepare the naming - theBoxAlgo->prepareNamingFaces(); - - // Insert to faces - std::map< std::string, std::shared_ptr > listOfFaces = - theBoxAlgo->getCreatedFaces(); - for (std::map< std::string, std::shared_ptr >::iterator it = listOfFaces.begin(); - it != listOfFaces.end(); - ++it) - { - theResultBox->generated((*it).second, (*it).first); + ResultPtr aVolume = document()->createVolume(data()); + setResult(aVolume); } }