X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FHYDROData%2FHYDROData_Profile.cxx;h=257dc01eb6387cc9427bc49e26ee2c95797749e7;hb=e75504ed446bb0bd2f5bf5649c787fe61adc9710;hp=9832cadb3a4a47fa95a35795a1d2ec5da90c2af5;hpb=8749815cc2069167555bf5e823190727b7004a35;p=modules%2Fhydro.git diff --git a/src/HYDROData/HYDROData_Profile.cxx b/src/HYDROData/HYDROData_Profile.cxx index 9832cadb..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; @@ -345,7 +356,7 @@ bool HYDROData_Profile::ImportFromFile( const Handle(HYDROData_Document)& theDoc // Close the file aFile.Close(); - for ( int i = 1, n = aCreatedProfiles.Length(); i < n ; ++i ) + for ( int i = 1, n = aCreatedProfiles.Length(); i <= n ; ++i ) { Handle(HYDROData_Profile) aProfile = aCreatedProfiles.Value( i ); if ( aRes )