_PTR(SObject) theSObject)
{
SalomeApp_Study* study = GetAppStudy( theModule );
- study->deleteReferencesTo( theSObject );
_PTR(ChildIterator) aChildIter = theStudy->NewChildIterator(theSObject);
for (aChildIter->InitEx(true); aChildIter->More(); aChildIter->Next()) {
_PTR(SObject) aChildSObject = aChildIter->Value();
- study->deleteReferencesTo( aChildSObject );
+
CORBA::Object_var aChildObj = VISU::ClientSObjectToObject(aChildSObject);
+ VISU::RemovableObject_var aRemovableObject = VISU::RemovableObject::_narrow(aChildObj);
+ if( !CORBA::is_nil( aRemovableObject ) )
+ study->deleteReferencesTo( aChildSObject );
ErasePrs(theModule, aChildObj);
}
VISU::RemovableObject_var aRemovableObject = VISU::RemovableObject::_narrow(anObj);
if (!CORBA::is_nil(aRemovableObject)) {
+ study->deleteReferencesTo( theSObject );
aRemovableObject->RemoveFromStudy();
}
} else {
if (aResActor)
return aResActor;
- anVISUActor = PublishInView( theModule, thePrs );
+ //anVISUActor = PublishInView( theModule, thePrs );
return anVISUActor;
}