Salome HOME
Result attributes validators created
[modules/shaper.git] / src / ModuleBase / ModuleBase_WidgetSelector.h
index 0d411f3b742b4f747bcb105120827446cf735cb4..1388bc77317fcc2addf1cad120bd7a155d46e719 100644 (file)
@@ -8,7 +8,7 @@
 #include "ModuleBase.h"
 #include "ModuleBase_ModelWidget.h"
 
-#include <ModelAPI_Feature.h>
+#include <ModelAPI_Object.h>
 
 #include <TopAbs_ShapeEnum.hxx>
 
@@ -28,15 +28,15 @@ class MODULEBASE_EXPORT ModuleBase_WidgetSelector: public ModuleBase_ModelWidget
 public:
   ModuleBase_WidgetSelector(QWidget* theParent, 
                             ModuleBase_IWorkshop* theWorkshop, 
-                            const Config_WidgetAPI* theData);
+                            const Config_WidgetAPI* theData, const std::string& theParentId);
 
   virtual ~ModuleBase_WidgetSelector();
 
   /// Saves the internal parameters to the given feature
-  /// \param theFeature a model feature to be changed
-  virtual bool storeValue(FeaturePtr theFeature) const;
+  /// \param theObject a model feature to be changed
+  virtual bool storeValue(ObjectPtr theObject) const;
 
-  virtual bool restoreValue(FeaturePtr theFeature);
+  virtual bool restoreValue(ObjectPtr theObject);
 
   /// Returns the internal parent wiget control, that can be shown anywhere
   /// \returns the widget
@@ -49,7 +49,7 @@ public:
   void setActivationOnStart(bool toActivate) { myActivateOnStart = toActivate; }
   bool activateOnStart() const { return myActivateOnStart; }
 
-  FeaturePtr selectedFeature() const { return mySelectedFeature; }
+  ObjectPtr selectedFeature() const { return mySelectedObject; }
 
 public slots:
 
@@ -66,7 +66,7 @@ private:
   void enableOthersControls(bool toEnable) const;
   void updateSelectionName();
   void raisePanel() const;
-  bool isAccepted(const FeaturePtr theFeature) const;
+  bool isAccepted(const ObjectPtr theObject) const;
 
   static TopAbs_ShapeEnum shapeType(const QString& theType);
 
@@ -79,7 +79,7 @@ private:
 
   bool myActivateOnStart;
 
-  FeaturePtr mySelectedFeature;
+  ObjectPtr mySelectedObject;
   QStringList myShapeTypes;
 };