Salome HOME
Issue #1648: Dump Python in the High Level Parameterized Geometry API
[modules/shaper.git] / src / ModelHighAPI / ModelHighAPI_Tools.cpp
index 7931f0dcae2a8e34eb8a91c1987348a9a8b1f98f..8923fd6e13bf01788622a586a564361eccb44709 100644 (file)
@@ -173,6 +173,13 @@ void fillAttribute(const std::list<ModelHighAPI_Selection> & theValue,
                    const std::shared_ptr<ModelAPI_AttributeSelectionList> & theAttribute)
 {
   theAttribute->clear();
+
+  if(!theValue.empty()) {
+    std::string aSelectionType;
+    const ModelHighAPI_Selection& aSelection = theValue.front();
+    theAttribute->setSelectionType(aSelection.shapeType());
+  }
+
   for (auto it = theValue.begin(); it != theValue.end(); ++it)
     it->appendToList(theAttribute);
 }