From: nds Date: Fri, 11 Sep 2015 08:46:08 +0000 (+0300) Subject: Update error manager processing. Error is got firstly from the feature, then from... X-Git-Tag: V_1.4.0_beta4~26 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=d8cc809e8cd33af42a2995b2c1fa08935f3151e0;p=modules%2Fshaper.git Update error manager processing. Error is got firstly from the feature, then from the GUI state. Do not use validationChanged and nestedChanged signals for this. Use direct methods updateAction of error manager. Update application Accept actions by signal of model about feature state change, but not by updated signal of object. --- diff --git a/src/PartSet/PartSet_SketcherMgr.cpp b/src/PartSet/PartSet_SketcherMgr.cpp index d11636140..50d4cd86e 100644 --- a/src/PartSet/PartSet_SketcherMgr.cpp +++ b/src/PartSet/PartSet_SketcherMgr.cpp @@ -694,8 +694,17 @@ QString PartSet_SketcherMgr::getFeatureError(const FeaturePtr& theFeature) (getCurrentOperation()); if (aFOperation) { FeaturePtr aFeature = aFOperation->feature(); - if (aFeature.get() && aFeature == theFeature && isNestedCreateOperation(aFOperation)) - anError = "Please input value in Property Panel. It is not initialized."; + if (aFeature.get() && aFeature == theFeature && isNestedCreateOperation(aFOperation)) { + QString anAttributeName = ""; + ModuleBase_IPropertyPanel* aPanel = aFOperation->propertyPanel(); + ModuleBase_ModelWidget* anActiveWgt = aPanel->activeWidget(); + if (anActiveWgt) { + AttributePtr anAttr = aFeature->attribute(anActiveWgt->attributeID()); + if (anAttr.get()) + anAttributeName = anAttr->id().c_str(); + } + anError = "Attribute \"" + anAttributeName + "\" is not initialized."; + } } } return anError;