Salome HOME
Task #3005 : To be able to create a group on a whole result
[modules/shaper.git] / src / XGUI / XGUI_InspectionPanel.cpp
index c77f750b8524e48113a57d159d2d98006cf6ee26..088f1eddc645a6cfb0fb623699c2b82dba9b4e6d 100644 (file)
@@ -24,6 +24,7 @@
 
 #include <ModuleBase_ViewerPrs.h>
 #include <ModuleBase_Tools.h>
+#include <ModelAPI_ResultField.h>
 
 #include <ModelAPI_Result.h>
 
@@ -154,9 +155,6 @@ XGUI_InspectionPanel::XGUI_InspectionPanel(QWidget* theParent, XGUI_SelectionMgr
   mySubShapesTab->setColumnWidth(0, 90);
   mySubShapesTab->setColumnWidth(1, 70);
 
-  //mySubShapesTab->setMaximumWidth(170);
-  //mySubShapesTab->setMinimumHeight(300);
-
   aSplitter->addWidget(mySubShapesTab);
 
   // Type of object
@@ -228,6 +226,10 @@ void XGUI_InspectionPanel::onSelectionChanged()
 
   if (aSelectedList.count() > 0) {
     ModuleBase_ViewerPrsPtr aPrs = aSelectedList.first();
+    FieldStepPtr aStep =
+      std::dynamic_pointer_cast<ModelAPI_ResultField::ModelAPI_FieldStep>(aPrs->object());
+    if (aStep)
+      return;
     TopoDS_Shape aShape = ModuleBase_Tools::getSelectedShape(aPrs);
     if (aShape.IsNull()) {
       ResultPtr aRes = std::dynamic_pointer_cast<ModelAPI_Result>(aPrs->object());