X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FHYDROGUI%2FHYDROGUI_Shape.cxx;h=37eaf35001c6050e1f74bab38968ac0aaa59cef9;hb=a1431f03eac1d1aed4203d0568d987c41ce939b3;hp=597c9db775e82e70464816dee99f4e502f7c7f1c;hpb=a830ea48321de9c8a753f7012f957fae3e7b5a45;p=modules%2Fhydro.git diff --git a/src/HYDROGUI/HYDROGUI_Shape.cxx b/src/HYDROGUI/HYDROGUI_Shape.cxx index 597c9db7..37eaf350 100644 --- a/src/HYDROGUI/HYDROGUI_Shape.cxx +++ b/src/HYDROGUI/HYDROGUI_Shape.cxx @@ -47,6 +47,7 @@ #include #include #include +#include #include #include @@ -350,6 +351,28 @@ void HYDROGUI_Shape::update( const bool theIsUpdateViewer ) setFillingColor( aFillingColor, false, false ); setBorderColor( aBorderColor, false, false ); } + else if ( myObject->IsKind( STANDARD_TYPE(HYDROData_ShapesGroup) ) ) + { + Handle(HYDROData_ShapesGroup) aShapesGroup = + Handle(HYDROData_ShapesGroup)::DownCast( myObject ); + + TopTools_SequenceOfShape aShapes; + aShapesGroup->GetShapes( aShapes ); + + BRepBuilderAPI_MakeWire aMakeWire; + + for ( int i = 1, n = aShapes.Length(); i <= n; ++i ) + { + TopoDS_Edge anEdge = TopoDS::Edge( aShapes.Value( i ) ); + aMakeWire.Add( anEdge ); + } + + aMakeWire.Build(); + TopoDS_Wire aResWire = aMakeWire.Wire(); + + setWire( aResWire, false, false ); + setBorderColor( Qt::red, false, false ); + } } if ( myShape.IsNull() || !isVisible() )