#include <Model_AttributeReference.h>
#include <Model_AttributeRefAttr.h>
#include <Model_AttributeRefList.h>
+#include <Model_AttributeBoolean.h>
#include <GeomData_Point.h>
#include <GeomData_Point2D.h>
#include <GeomData_Dir.h>
anAttr = new GeomData_Dir(anAttrLab);
else if (theAttrType == GeomData_Point2D::type())
anAttr = new GeomData_Point2D(anAttrLab);
+ else if (theAttrType == Model_AttributeBoolean::type())
+ anAttr = new Model_AttributeBoolean(anAttrLab);
if (anAttr) {
myAttrs[theID] = boost::shared_ptr<ModelAPI_Attribute>(anAttr);
return aRes;
}
+boost::shared_ptr<ModelAPI_AttributeBoolean> Model_Data::boolean(const std::string theID)
+{
+ map<string, boost::shared_ptr<ModelAPI_Attribute> >::iterator aFound = myAttrs.find(theID);
+ if (aFound == myAttrs.end()) {
+ // TODO: generate error on unknown attribute request and/or add mechanism for customization
+ return boost::shared_ptr<ModelAPI_AttributeBoolean>();
+ }
+ boost::shared_ptr<ModelAPI_AttributeBoolean> aRes =
+ boost::dynamic_pointer_cast<ModelAPI_AttributeBoolean>(aFound->second);
+ if (!aRes) {
+ // TODO: generate error on invalid attribute type request
+ }
+ return aRes;
+}
+
boost::shared_ptr<ModelAPI_AttributeReference> Model_Data::reference(const string theID)
{
map<string, boost::shared_ptr<ModelAPI_Attribute> >::iterator aFound = myAttrs.find(theID);
/// Returns the attribute that contains list of references to features
MODEL_EXPORT virtual boost::shared_ptr<ModelAPI_AttributeRefList>
reflist(const std::string theID);
+ /// Returns the attribute that contains boolean value
+ MODEL_EXPORT virtual boost::shared_ptr<ModelAPI_AttributeBoolean>
+ boolean(const std::string theID);
/// Returns the generic attribute by identifier
/// \param theID identifier of the attribute
MODEL_EXPORT virtual boost::shared_ptr<ModelAPI_Attribute> attribute(const std::string theID);
class ModelAPI_AttributeReference;
class ModelAPI_AttributeRefAttr;
class ModelAPI_AttributeRefList;
+class ModelAPI_AttributeBoolean;
class ModelAPI_Document;
class ModelAPI_Attribute;
class GeomAPI_Shape;
virtual boost::shared_ptr<ModelAPI_AttributeRefAttr> refattr(const std::string theID) = 0;
/// Returns the attribute that contains list of references to features
virtual boost::shared_ptr<ModelAPI_AttributeRefList> reflist(const std::string theID) = 0;
+ /// Returns the attribute that contains boolean value
+ virtual boost::shared_ptr<ModelAPI_AttributeBoolean> boolean(const std::string theID) = 0;
/// Returns the generic attribute by identifier
/// \param theID identifier of the attribute
ModuleBase_MetaWidget.h
ModuleBase_SelectorWidget.h
ModuleBase_IWorkshop.h
+ ModuleBase_Widgets.h
)
SET(PROJECT_SOURCES
ModuleBase_WidgetSwitch.cpp
ModuleBase_MetaWidget.cpp
ModuleBase_SelectorWidget.cpp
+ ModuleBase_Widgets.cpp
)
SET(PROJECT_LIBRARIES
/// Saves the internal parameters to the given feature
/// \param theFeature a model feature to be changed
- virtual bool storeValue(FeaturePtr theFeature) = 0;
+ virtual bool storeValue(FeaturePtr theFeature) const = 0;
virtual bool restoreValue(FeaturePtr theFeature) = 0;
/// Returns whether the widget can accept focus, or if it corresponds to the given attribute
/// \param theAttribute name
- virtual bool canFocusTo(const std::string& theAttributeName) = 0;
+ virtual bool canFocusTo(const std::string& theAttributeName) const { return false; }
/// Set focus to the current widget if it corresponds to the given attribute
- virtual void focusTo() = 0;
+ virtual void focusTo() {}
/// Returns list of widget controls
/// \return a control list
#endif
ModuleBase_Operation::ModuleBase_Operation(const QString& theId, QObject* theParent)
-: ModuleBase_IOperation(theId, theParent)
+: ModuleBase_IOperation(theId, theParent), myIsEditing(false)
{
}
void ModuleBase_Operation::startOperation()
{
- if (!myFeature)
+ if (!myIsEditing)
setFeature(createFeature());
//emit callSlot();
//commit();
{
myFeature = theFeature;
}
+
+void ModuleBase_Operation::setEditingFeature(FeaturePtr theFeature)
+{
+ myFeature = theFeature;
+ myIsEditing = true;
+}
virtual void keyReleased(std::string theName, QKeyEvent* theEvent) {};
/// Sets the operation feature
- void setFeature(FeaturePtr theFeature);
+ void setEditingFeature(FeaturePtr theFeature);
+
+ bool isEditOperation() const { return myIsEditing; }
protected:
/// Virtual method called when operation started (see start() method for more description)
/// \returns the created feature
virtual FeaturePtr createFeature(const bool theFlushMessage = true);
+ /// Sets the operation feature
+ void setFeature(FeaturePtr theFeature);
+
private:
FeaturePtr myFeature; /// the operation feature to be handled
+
+ bool myIsEditing;
};
#endif
#include <QToolButton>
#include <QString>
#include <QEvent>
+#include <QDockWidget>
ModuleBase_SelectorWidget::ModuleBase_SelectorWidget(QWidget* theParent,
}
//********************************************************************
-bool ModuleBase_SelectorWidget::storeValue(FeaturePtr theFeature)
+bool ModuleBase_SelectorWidget::storeValue(FeaturePtr theFeature) const
{
DataPtr aData = theFeature->data();
boost::shared_ptr<ModelAPI_AttributeReference> aRef =
boost::dynamic_pointer_cast<ModelAPI_AttributeReference>(aData->attribute(myFeatureAttributeID));
- bool isBlocked = this->blockSignals(true);
- aRef->setValue(mySelectedFeature);
- Events_Loop::loop()->flush(Events_Loop::eventByName(EVENT_FEATURE_UPDATED));
-
- this->blockSignals(isBlocked);
+ FeaturePtr aFeature = aRef->value();
+ if (!(aFeature && aFeature->isSame(mySelectedFeature))) {
+ aRef->setValue(mySelectedFeature);
+ Events_Loop::loop()->flush(Events_Loop::eventByName(EVENT_FEATURE_UPDATED));
+ }
return true;
}
bool ModuleBase_SelectorWidget::restoreValue(FeaturePtr theFeature)
{
DataPtr aData = theFeature->data();
- boost::shared_ptr<ModelAPI_AttributeReference> aRef =
- boost::dynamic_pointer_cast<ModelAPI_AttributeReference>(aData->attribute(myFeatureAttributeID));
+ boost::shared_ptr<ModelAPI_AttributeReference> aRef = aData->reference(myFeatureAttributeID);
bool isBlocked = this->blockSignals(true);
mySelectedFeature = aRef->value();
return true;
}
-//********************************************************************
-bool ModuleBase_SelectorWidget::canFocusTo(const std::string& theAttributeName)
-{
- return false;
-}
-
-//********************************************************************
-void ModuleBase_SelectorWidget::focusTo()
-{
-}
-
//********************************************************************
QList<QWidget*> ModuleBase_SelectorWidget::getControls() const
{
if (mySelectedFeature) {
updateSelectionName();
activateSelection(false);
+ raisePanel();
} else {
myTextLine->setText("");
}
}
//********************************************************************
-void ModuleBase_SelectorWidget::enableOthersControls(bool toEnable)
+void ModuleBase_SelectorWidget::enableOthersControls(bool toEnable) const
{
QWidget* aParent = myContainer->parentWidget();
QList<QWidget*> aChldList = aParent->findChildren<QWidget*>();
disconnect(myWorkshop, SIGNAL(selectionChanged()), this, SLOT(onSelectionChanged()));
myActivateBtn->setDown(toActivate);
+}
+
+//********************************************************************
+void ModuleBase_SelectorWidget::raisePanel() const
+{
+ QWidget* aParent = myContainer->parentWidget();
+ QWidget* aLastPanel = 0;
+ while (!aParent->inherits("QDockWidget")) {
+ aLastPanel = aParent;
+ aParent = aParent->parentWidget();
+ if (!aParent) return;
+ }
+ if (aParent->inherits("QDockWidget")) {
+ QDockWidget* aTabWgt = (QDockWidget*) aParent;
+ aTabWgt->raise();
+ }
}
\ No newline at end of file
/// Saves the internal parameters to the given feature
/// \param theFeature a model feature to be changed
- virtual bool storeValue(FeaturePtr theFeature);
+ virtual bool storeValue(FeaturePtr theFeature) const;
virtual bool restoreValue(FeaturePtr theFeature);
- /// Returns whether the widget can accept focus, or if it corresponds to the given attribute
- /// \param theAttribute name
- virtual bool canFocusTo(const std::string& theAttributeName);
-
- /// Set focus to the current widget if it corresponds to the given attribute
- virtual void focusTo();
-
/// Returns the internal parent wiget control, that can be shown anywhere
/// \returns the widget
QWidget* getControl() const { return myContainer; }
void onSelectionChanged();
private:
- void enableOthersControls(bool toEnable);
+ void enableOthersControls(bool toEnable) const;
void updateSelectionName();
+ void raisePanel() const;
std::string myFeatureAttributeID;
#include <ModuleBase_WidgetFactory.h>
-#include <ModuleBase_MetaWidget.h>
#include <ModuleBase_Operation.h>
#include <ModuleBase_OperationDescription.h>
#include <ModuleBase_WidgetPoint2D.h>
#include <ModuleBase_WidgetSwitch.h>
#include <ModuleBase_SelectorWidget.h>
+#include <ModuleBase_Widgets.h>
#include <Config_Keywords.h>
#include <Config_WidgetAPI.h>
#include <QPixmap>
#include <QGroupBox>
#include <QToolBox>
-#include <QCheckBox>
#ifdef _DEBUG
#include <QDebug>
{
QWidget* result = NULL;
if (theType == WDG_DOUBLEVALUE) {
- result = doubleSpinBoxControl();
+ result = doubleSpinBoxControl(theParent);
} else if (theType == WDG_INFO) {
result = labelControl(theParent);
return result;
}
-QWidget* ModuleBase_WidgetFactory::doubleSpinBoxControl()
+QWidget* ModuleBase_WidgetFactory::doubleSpinBoxControl(QWidget* theParent)
{
- QWidget* result = new QWidget();
- QHBoxLayout* aControlLay = new QHBoxLayout(result);
- aControlLay->setContentsMargins(0, 0, 0, 0);
- QString aLabelText = qs(myWidgetApi->widgetLabel());
- QString aLabelIcon = qs(myWidgetApi->widgetIcon());
- QLabel* aLabel = new QLabel(aLabelText);
- aLabel->setPixmap(QPixmap(aLabelIcon));
-
- aControlLay->addWidget(aLabel);
- QDoubleSpinBox* aBox = new QDoubleSpinBox(result);
- QString anObjName = QString::fromStdString(myWidgetApi->widgetId());
- aBox->setObjectName(anObjName);
- bool isOk = false;
- std::string aProp = myWidgetApi->getProperty(DOUBLE_WDG_MIN);
- double aMinVal = qs(aProp).toDouble(&isOk);
- if (isOk) {
- aBox->setMinimum(aMinVal);
- } else {
- aBox->setMinimum(-DBL_MAX);
- }
- aProp = myWidgetApi->getProperty(DOUBLE_WDG_MAX);
- double aMaxVal = qs(aProp).toDouble(&isOk);
- if (isOk) {
- aBox->setMaximum(aMaxVal);
- } else {
- aBox->setMaximum(DBL_MAX);
- }
- aProp = myWidgetApi->getProperty(DOUBLE_WDG_STEP);
- double aStepVal = qs(aProp).toDouble(&isOk);
- if (isOk) {
- aBox->setSingleStep(aStepVal);
- }
- aProp = myWidgetApi->getProperty(DOUBLE_WDG_DFLT);
- double aDefVal = qs(aProp).toDouble(&isOk);
- if (isOk) {
- aBox->setValue(aDefVal);
- }
- QString aTTip = qs(myWidgetApi->widgetTooltip());
- aBox->setToolTip(aTTip);
- aControlLay->addWidget(aBox);
- aControlLay->setStretch(1, 1);
- result->setLayout(aControlLay);
- connectWidget(aBox, WDG_DOUBLEVALUE);
- return result;
+ ModuleBase_DoubleValueWidget* aDblWgt = new ModuleBase_DoubleValueWidget(theParent, myWidgetApi);
+ QObject::connect(aDblWgt, SIGNAL(valuesChanged()), myOperation, SLOT(storeCustomValue()));
+
+ myModelWidgets.append(aDblWgt);
+
+ // Init default values
+ if (!myOperation->isEditOperation())
+ aDblWgt->storeValue(myOperation->feature());
+ return aDblWgt->getControl();
}
QWidget* ModuleBase_WidgetFactory::pointSelectorControl(QWidget* theParent)
QWidget* ModuleBase_WidgetFactory::booleanControl(QWidget* theParent)
{
- QString aText = qs(myWidgetApi->widgetLabel());
- QString aToolTip = qs(myWidgetApi->widgetTooltip());
- QString aDefault = qs(myWidgetApi->getProperty("default"));
-
- QCheckBox* aRes = new QCheckBox(aText, theParent);
- aRes->setToolTip(aToolTip);
- aRes->setChecked(aDefault == "true");
- return aRes;
+ ModuleBase_BoolValueWidget* aBoolWgt = new ModuleBase_BoolValueWidget(theParent, myWidgetApi);
+ QObject::connect(aBoolWgt, SIGNAL(valuesChanged()), myOperation, SLOT(storeCustomValue()));
+
+ myModelWidgets.append(aBoolWgt);
+
+ // Init default values
+ if (!myOperation->isEditOperation())
+ aBoolWgt->storeValue(myOperation->feature());
+ return aBoolWgt->getControl();
}
\ No newline at end of file
//Widgets
QWidget* createWidgetByType(const std::string& theType, QWidget* theParent = NULL);
QWidget* labelControl(QWidget* theParent);
- QWidget* doubleSpinBoxControl();
+ QWidget* doubleSpinBoxControl(QWidget* theParent);
QWidget* pointSelectorControl(QWidget* theParent);
QWidget* createContainer(const std::string& theType, QWidget* theParent = NULL);
QWidget* selectorControl(QWidget* theParent);
{
}
-bool ModuleBase_WidgetPoint2D::storeValue(FeaturePtr theFeature)
+bool ModuleBase_WidgetPoint2D::storeValue(FeaturePtr theFeature) const
{
boost::shared_ptr<ModelAPI_Data> aData = theFeature->data();
boost::shared_ptr<GeomDataAPI_Point2D> aPoint =
boost::dynamic_pointer_cast<GeomDataAPI_Point2D>(aData->attribute(myFeatureAttributeID));
- bool isBlocked = this->blockSignals(true);
+ ModuleBase_WidgetPoint2D* that = (ModuleBase_WidgetPoint2D*) this;
+ bool isBlocked = that->blockSignals(true);
aPoint->setValue(myXSpin->value(), myYSpin->value());
Events_Loop::loop()->flush(Events_Loop::eventByName(EVENT_FEATURE_UPDATED));
+ that->blockSignals(isBlocked);
- this->blockSignals(isBlocked);
return true;
}
/// Saves the internal parameters to the given feature
/// \param theFeature a model feature to be changed
- virtual bool storeValue(FeaturePtr theFeature);
+ virtual bool storeValue(FeaturePtr theFeature) const;
virtual bool restoreValue(FeaturePtr theFeature);
--- /dev/null
+// File: ModuleBase_Widgets.h
+// Created: 04 June 2014
+// Author: Vitaly Smetannikov
+
+#include "ModuleBase_Widgets.h"
+
+#include <ModelAPI_AttributeDouble.h>
+#include <ModelAPI_AttributeBoolean.h>
+#include <ModelAPI_Data.h>
+
+#include <Config_Keywords.h>
+#include <Config_WidgetAPI.h>
+
+#include <Events_Loop.h>
+#include <Model_Events.h>
+
+#include <QWidget>
+#include <QLayout>
+#include <QLabel>
+#include <QDoubleSpinBox>
+#include <QCheckBox>
+
+
+ModuleBase_DoubleValueWidget::ModuleBase_DoubleValueWidget(QWidget* theParent, const Config_WidgetAPI* theData)
+ : ModuleBase_ModelWidget(theParent)
+{
+ myContainer = new QWidget(theParent);
+ QHBoxLayout* aControlLay = new QHBoxLayout(myContainer);
+ aControlLay->setContentsMargins(0, 0, 0, 0);
+
+ QString aLabelText = QString::fromStdString(theData->widgetLabel());
+ QString aLabelIcon = QString::fromStdString(theData->widgetIcon());
+ myLabel = new QLabel(aLabelText, myContainer);
+ myLabel->setPixmap(QPixmap(aLabelIcon));
+ aControlLay->addWidget(myLabel);
+
+ myAttributeID = theData->widgetId();
+ mySpinBox = new QDoubleSpinBox(myContainer);
+ QString anObjName = QString::fromStdString(myAttributeID);
+ mySpinBox->setObjectName(anObjName);
+
+ bool isOk = false;
+ std::string aProp = theData->getProperty(DOUBLE_WDG_MIN);
+ double aMinVal = QString::fromStdString(aProp).toDouble(&isOk);
+ if (isOk) {
+ mySpinBox->setMinimum(aMinVal);
+ } else {
+ mySpinBox->setMinimum(-DBL_MAX);
+ }
+
+ aProp = theData->getProperty(DOUBLE_WDG_MAX);
+ double aMaxVal = QString::fromStdString(aProp).toDouble(&isOk);
+ if (isOk) {
+ mySpinBox->setMaximum(aMaxVal);
+ } else {
+ mySpinBox->setMaximum(DBL_MAX);
+ }
+
+ aProp = theData->getProperty(DOUBLE_WDG_STEP);
+ double aStepVal = QString::fromStdString(aProp).toDouble(&isOk);
+ if (isOk) {
+ mySpinBox->setSingleStep(aStepVal);
+ }
+
+ aProp = theData->getProperty(DOUBLE_WDG_DFLT);
+ double aDefVal = QString::fromStdString(aProp).toDouble(&isOk);
+ if (isOk) {
+ mySpinBox->setValue(aDefVal);
+ }
+
+ QString aTTip = QString::fromStdString(theData->widgetTooltip());
+ mySpinBox->setToolTip(aTTip);
+
+ aControlLay->addWidget(mySpinBox);
+ aControlLay->setStretch(1, 1);
+
+ connect(mySpinBox, SIGNAL(valueChanged(double)), this, SIGNAL(valuesChanged()));
+}
+
+ModuleBase_DoubleValueWidget::~ModuleBase_DoubleValueWidget()
+{
+}
+
+bool ModuleBase_DoubleValueWidget::storeValue(FeaturePtr theFeature) const
+{
+ DataPtr aData = theFeature->data();
+ boost::shared_ptr<ModelAPI_AttributeDouble> aReal = aData->real(myAttributeID);
+ if (aReal->value() != mySpinBox->value()) {
+ aReal->setValue(mySpinBox->value());
+ Events_Loop::loop()->flush(Events_Loop::eventByName(EVENT_FEATURE_UPDATED));
+ }
+ return true;
+}
+
+bool ModuleBase_DoubleValueWidget::restoreValue(FeaturePtr theFeature)
+{
+ DataPtr aData = theFeature->data();
+ boost::shared_ptr<ModelAPI_AttributeDouble> aRef = aData->real(myAttributeID);
+
+ bool isBlocked = mySpinBox->blockSignals(true);
+ mySpinBox->setValue(aRef->value());
+ mySpinBox->blockSignals(isBlocked);
+
+ return true;
+}
+
+QList<QWidget*> ModuleBase_DoubleValueWidget::getControls() const
+{
+ QList<QWidget*> aList;
+ aList.append(myLabel);
+ aList.append(mySpinBox);
+ return aList;
+}
+
+
+//////////////////////////////////////////////////////////////////////////////////
+ModuleBase_BoolValueWidget::ModuleBase_BoolValueWidget(QWidget* theParent, const Config_WidgetAPI* theData)
+ : ModuleBase_ModelWidget(theParent)
+{
+ myAttributeID = theData->widgetId();
+ QString aText = QString::fromStdString(theData->widgetLabel());
+ QString aToolTip = QString::fromStdString(theData->widgetTooltip());
+ QString aDefault = QString::fromStdString(theData->getProperty("default"));
+
+ myCheckBox = new QCheckBox(aText, theParent);
+ myCheckBox->setToolTip(aToolTip);
+ myCheckBox->setChecked(aDefault == "true");
+
+ connect(myCheckBox, SIGNAL(toggled(bool)), this, SIGNAL(valuesChanged()));
+}
+
+ModuleBase_BoolValueWidget::~ModuleBase_BoolValueWidget()
+{
+}
+
+QWidget* ModuleBase_BoolValueWidget::getControl() const
+{
+ return myCheckBox;
+}
+
+bool ModuleBase_BoolValueWidget::storeValue(FeaturePtr theFeature) const
+{
+ DataPtr aData = theFeature->data();
+ boost::shared_ptr<ModelAPI_AttributeBoolean> aBool = aData->boolean(myAttributeID);
+
+ if (aBool->value() != myCheckBox->isChecked()) {
+ aBool->setValue(myCheckBox->isChecked());
+ Events_Loop::loop()->flush(Events_Loop::eventByName(EVENT_FEATURE_UPDATED));
+ }
+ return true;
+}
+
+bool ModuleBase_BoolValueWidget::restoreValue(FeaturePtr theFeature)
+{
+ DataPtr aData = theFeature->data();
+ boost::shared_ptr<ModelAPI_AttributeBoolean> aRef = aData->boolean(myAttributeID);
+
+ bool isBlocked = myCheckBox->blockSignals(true);
+ myCheckBox->setChecked(aRef->value());
+ myCheckBox->blockSignals(isBlocked);
+
+ return true;
+}
+
+QList<QWidget*> ModuleBase_BoolValueWidget::getControls() const
+{
+ QList<QWidget*> aList;
+ aList.append(myCheckBox);
+ return aList;
+}
--- /dev/null
+// File: ModuleBase_Widgets.h
+// Created: 04 June 2014
+// Author: Vitaly Smetannikov
+
+#ifndef ModuleBase_Widgets_H
+#define ModuleBase_Widgets_H
+
+#include "ModuleBase.h"
+#include "ModuleBase_ModelWidget.h"
+
+class Config_WidgetAPI;
+class QWidget;
+class QLabel;
+class QDoubleSpinBox;
+class QCheckBox;
+
+class MODULEBASE_EXPORT ModuleBase_DoubleValueWidget: public ModuleBase_ModelWidget
+{
+ Q_OBJECT
+public:
+ ModuleBase_DoubleValueWidget(QWidget* theParent, const Config_WidgetAPI* theData);
+
+ virtual ~ModuleBase_DoubleValueWidget();
+
+ /// Saves the internal parameters to the given feature
+ /// \param theFeature a model feature to be changed
+ virtual bool storeValue(FeaturePtr theFeature) const;
+
+ virtual bool restoreValue(FeaturePtr theFeature);
+
+ /// Returns list of widget controls
+ /// \return a control list
+ virtual QList<QWidget*> getControls() const;
+
+ /// Returns the internal parent wiget control, that can be shown anywhere
+ /// \returns the widget
+ QWidget* getControl() const { return myContainer; }
+
+private:
+ std::string myAttributeID;
+
+ QWidget* myContainer;
+ QLabel* myLabel;
+ QDoubleSpinBox* mySpinBox;
+};
+
+
+//////////////////////////////////////////////////////////////////////////////////
+
+class MODULEBASE_EXPORT ModuleBase_BoolValueWidget: public ModuleBase_ModelWidget
+{
+ Q_OBJECT
+public:
+ ModuleBase_BoolValueWidget(QWidget* theParent, const Config_WidgetAPI* theData);
+
+ virtual ~ModuleBase_BoolValueWidget();
+
+ /// Saves the internal parameters to the given feature
+ /// \param theFeature a model feature to be changed
+ virtual bool storeValue(FeaturePtr theFeature) const;
+
+ virtual bool restoreValue(FeaturePtr theFeature);
+
+ /// Returns list of widget controls
+ /// \return a control list
+ virtual QList<QWidget*> getControls() const;
+
+ /// Returns the internal parent wiget control, that can be shown anywhere
+ /// \returns the widget
+ QWidget* getControl() const;
+
+private:
+ std::string myAttributeID;
+
+ QCheckBox* myCheckBox;
+};
+
+#endif
\ No newline at end of file
std::list<XGUI_ViewerPrs> aHighlighted = aDisplayer->getHighlighted(TopAbs_VERTEX);
aPreviewOp->init(theFeature, aSelected, aHighlighted);
} else {
- anOperation->setFeature(theFeature);
+ anOperation->setEditingFeature(theFeature);
}
sendOperation(anOperation);
myWorkshop->actionsMgr()->updateCheckState();