From a28a6cccd566a266f6fe3a372d6059f660851074 Mon Sep 17 00:00:00 2001 From: mpv Date: Mon, 8 Dec 2014 09:14:58 +0300 Subject: [PATCH] Concealed objects now also ersaed in the viewer --- src/Model/Model_Data.cpp | 1 - src/Model/Model_Document.cpp | 4 ++++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/Model/Model_Data.cpp b/src/Model/Model_Data.cpp index 0ae7a75aa..b10378943 100644 --- a/src/Model/Model_Data.cpp +++ b/src/Model/Model_Data.cpp @@ -265,7 +265,6 @@ void Model_Data::referencesToObjects( std::shared_ptr aRef = std::dynamic_pointer_cast< ModelAPI_AttributeReference>(anAttr->second); aReferenced.push_back(aRef->value()); - theRefs.push_back(std::pair >(anAttr->first, aReferenced)); } else if (aType == ModelAPI_AttributeRefAttr::type()) { // reference to attribute or object std::shared_ptr aRef = std::dynamic_pointer_cast< ModelAPI_AttributeRefAttr>(anAttr->second); diff --git a/src/Model/Model_Document.cpp b/src/Model/Model_Document.cpp index 0fa26c8d4..6c817c4b3 100644 --- a/src/Model/Model_Document.cpp +++ b/src/Model/Model_Document.cpp @@ -885,6 +885,10 @@ void Model_Document::synchronizeBackRefs() ModelAPI_EventCreator::get()->sendUpdated(aCIter->first, anEvent); } else { // was not concealed become concealed => delete event ModelAPI_EventCreator::get()->sendDeleted(aThis, aCIter->first->groupName()); + // redisplay for the viewer (it must be disappeared also) + static Events_ID EVENT_DISP = + Events_Loop::loop()->eventByName(EVENT_OBJECT_TO_REDISPLAY); + ModelAPI_EventCreator::get()->sendUpdated(aCIter->first, EVENT_DISP); } } } -- 2.39.2