mirror of
https://git.salome-platform.org/gitpub/modules/geom.git
synced 2025-01-13 02:00:35 +05:00
PAL8376
This commit is contained in:
parent
aa5ce1d37f
commit
6e6e07edd6
@ -116,7 +116,6 @@ static void indicesToOwners( const TColStd_IndexedMapOfInteger& aIndexMap,
|
||||
GEOM_AISShape::GEOM_AISShape(const TopoDS_Shape& shape,
|
||||
const Standard_CString aName): SALOME_AISShape(shape)
|
||||
{
|
||||
myIO = NULL;
|
||||
myName = new char [strlen(aName)+1];
|
||||
strcpy( myName, aName);
|
||||
|
||||
@ -124,15 +123,18 @@ GEOM_AISShape::GEOM_AISShape(const TopoDS_Shape& shape,
|
||||
}
|
||||
|
||||
void GEOM_AISShape::setIO(const Handle(SALOME_InteractiveObject)& io){
|
||||
myIO = io;
|
||||
SetOwner( io );
|
||||
}
|
||||
|
||||
Handle(SALOME_InteractiveObject) GEOM_AISShape::getIO(){
|
||||
return myIO;
|
||||
Handle(SALOME_InteractiveObject) IO;
|
||||
if ( !GetOwner().IsNull() )
|
||||
IO = Handle(SALOME_InteractiveObject)::DownCast( GetOwner() );
|
||||
return IO;
|
||||
}
|
||||
|
||||
Standard_Boolean GEOM_AISShape::hasIO(){
|
||||
return !myIO.IsNull();
|
||||
return !getIO().IsNull();
|
||||
}
|
||||
|
||||
void GEOM_AISShape::setName(const Standard_CString aName)
|
||||
@ -140,8 +142,9 @@ void GEOM_AISShape::setName(const Standard_CString aName)
|
||||
myName = new char [strlen(aName)+1];
|
||||
strcpy( myName, aName);
|
||||
|
||||
if ( hasIO() )
|
||||
myIO->setName(aName);
|
||||
Handle(SALOME_InteractiveObject) IO = getIO();
|
||||
if ( !IO.IsNull() )
|
||||
IO->setName(aName);
|
||||
}
|
||||
|
||||
Standard_CString GEOM_AISShape::getName(){
|
||||
|
@ -121,7 +121,6 @@ private:
|
||||
|
||||
// Fields PRIVATE
|
||||
//
|
||||
Handle_SALOME_InteractiveObject myIO;
|
||||
Standard_CString myName;
|
||||
Quantity_Color myShadingColor;
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user