X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FModelAPI%2FModelAPI_Result.cpp;h=588d138bf17cb447927b3273fed0f6fdfbeb1988;hb=dd51a000adf460a28f9f942bd83ce074db9e6a4d;hp=6569136a672e789abffecc1f4441154fcd0ccae6;hpb=a94fc319f2aa64b43c9a73b5ff7063923648faec;p=modules%2Fshaper.git diff --git a/src/ModelAPI/ModelAPI_Result.cpp b/src/ModelAPI/ModelAPI_Result.cpp index 6569136a6..588d138bf 100644 --- a/src/ModelAPI/ModelAPI_Result.cpp +++ b/src/ModelAPI/ModelAPI_Result.cpp @@ -37,13 +37,15 @@ void ModelAPI_Result::initAttributes() DataPtr aData = data(); aData->addAttribute(COLOR_ID(), ModelAPI_AttributeIntArray::typeId()); aData->addAttribute(DEFLECTION_ID(), ModelAPI_AttributeDouble::typeId()); + aData->addAttribute(TRANSPARENCY_ID(), ModelAPI_AttributeDouble::typeId()); } bool ModelAPI_Result::setDisabled(std::shared_ptr theThis, const bool theFlag) { if (myIsDisabled != theFlag) { myIsDisabled = theFlag; - data()->setIsDeleted(theFlag); // store it in data model (to get back on undo/redo, etc) + if (data()->isValid()) + data()->setIsDeleted(theFlag); // store it in data model (to get back on undo/redo, etc) // this must be before "updated" message send to have history updated for OB update document()->updateHistory(groupName()); // to update the history cash data in the document // generate related events