X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FHYDROData%2FHYDROData_Region.cxx;h=166806535995977ecdb0d576de304e449544c235;hb=f108c7fd8c3b2dbb8c263b14456a31f8dd1d0921;hp=2550de1fc64a201805403504060d4227c42ee2a2;hpb=b20ed0044cebfdd161511eae3dd31f3d0ccc8810;p=modules%2Fhydro.git diff --git a/src/HYDROData/HYDROData_Region.cxx b/src/HYDROData/HYDROData_Region.cxx index 2550de1f..16680653 100644 --- a/src/HYDROData/HYDROData_Region.cxx +++ b/src/HYDROData/HYDROData_Region.cxx @@ -1,6 +1,10 @@ #include "HYDROData_Region.h" +#include +#include +#include + #include #define PYTHON_REGION_ID "KIND_REGION" @@ -18,6 +22,20 @@ HYDROData_Region::~HYDROData_Region() { } +void HYDROData_Region::SetFace( const TopoDS_Face& theFace ) +{ + TNaming_Builder aBuilder( myLab ); + aBuilder.Generated( theFace ); +} + +TopoDS_Face HYDROData_Region::Face() const +{ + Handle(TNaming_NamedShape) aNamedShape; + if( myLab.FindAttribute( TNaming_NamedShape::GetID(), aNamedShape ) ) + return TopoDS::Face( aNamedShape->Get() ); + return TopoDS_Face(); +} + QString HYDROData_Region::getPythonKindId() const { return QString( PYTHON_REGION_ID );