From: adv Date: Wed, 27 Nov 2013 11:25:57 +0000 (+0000) Subject: Invalidate method added. X-Git-Tag: issue_132_11_28~18 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=1bbabb6a4145a459a6655a3bc18b71ec135bf814;p=modules%2Fhydro.git Invalidate method added. --- diff --git a/src/HYDROData/HYDROData_Profile.cxx b/src/HYDROData/HYDROData_Profile.cxx index 2c4088c0..257dc01e 100755 --- a/src/HYDROData/HYDROData_Profile.cxx +++ b/src/HYDROData/HYDROData_Profile.cxx @@ -175,6 +175,17 @@ bool HYDROData_Profile::GetLastPoint( gp_XY& thePoint ) const return true; } +void HYDROData_Profile::Invalidate() +{ + TDF_Label aFirstLabel = myLab.FindChild( DataTag_FirstPoint, false ); + if ( !aFirstLabel.IsNull() ) + aFirstLabel.ForgetAllAttributes(); + + TDF_Label aLastLabel = myLab.FindChild( DataTag_LastPoint, false ); + if ( !aLastLabel.IsNull() ) + aLastLabel.ForgetAllAttributes(); +} + Handle(HYDROData_ProfileUZ) HYDROData_Profile::GetProfileUZ( const bool theIsCreate ) const { Handle(HYDROData_ProfileUZ) aProfileUZ; diff --git a/src/HYDROData/HYDROData_Profile.h b/src/HYDROData/HYDROData_Profile.h index e31e6fd4..08383187 100644 --- a/src/HYDROData/HYDROData_Profile.h +++ b/src/HYDROData/HYDROData_Profile.h @@ -74,6 +74,11 @@ public: */ HYDRODATA_EXPORT bool IsValid() const; + /** + * Invalidate profile first and last points. + */ + HYDRODATA_EXPORT void Invalidate(); + public: // Public methods to work with profile points.