}
return newName;
}
+
+void SalomeApp_Study::deleteReferencesTo( _PTR( SObject ) obj )
+{
+ _PTR(StudyBuilder) sb = studyDS()->NewBuilder();
+ std::vector<_PTR(SObject)> aRefs = studyDS()->FindDependances( obj );
+ for( int i=0, n=aRefs.size(); i<n; i++ )
+ {
+ _PTR( SObject ) o = aRefs[i];
+ if( o->GetFatherComponent()->ComponentDataType()==obj->GetFatherComponent()->ComponentDataType() )
+ {
+ sb->RemoveReference( o );
+ sb->RemoveObjectWithChildren( o );
+ }
+ }
+}
_PTR(Study) studyDS() const;
+ // to delete all references to object, whose have the same component
+ void deleteReferencesTo( _PTR( SObject ) );
+
signals:
void saved( SUIT_Study* );
void opened( SUIT_Study* );