From: mzn Date: Wed, 29 Jan 2014 08:36:14 +0000 (+0000) Subject: Bug #334: Different behavior in Edit calculation case input panel. X-Git-Tag: BR_hydro_v_1_0~35 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=c8eaebcdfbf95840f1f191c2e6ef73fe377df3f3;p=modules%2Fhydro.git Bug #334: Different behavior in Edit calculation case input panel. --- diff --git a/src/HYDROGUI/HYDROGUI_CalculationOp.cxx b/src/HYDROGUI/HYDROGUI_CalculationOp.cxx index 377e821b..f6bd8449 100644 --- a/src/HYDROGUI/HYDROGUI_CalculationOp.cxx +++ b/src/HYDROGUI/HYDROGUI_CalculationOp.cxx @@ -797,8 +797,15 @@ void HYDROGUI_CalculationOp::setAvailableGroups() aGroupsNames.append( aGroup->GetName() ); } } - if( myEditedObject->IsMustBeUpdated() ) - myEditedObject->RemoveGeometryGroups(); + if( myEditedObject->IsMustBeUpdated() ) { + for( int anIndex = 1, aLength = aSeq.Length(); anIndex <= aLength; anIndex++ ) { + Handle(HYDROData_ShapesGroup) aGeomGroup = + Handle(HYDROData_ShapesGroup)::DownCast( aSeq.Value( anIndex ) ); + if ( !aGeomGroup.IsNull() && !aGroupsNames.contains( aGeomGroup->GetName() ) ) { + myEditedObject->RemoveGeometryGroup( aGeomGroup ); + } + } + } aPanel->setAvailableGroups( aGroupsNames ); aPanel->includeGroups( aList );