X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FStdMeshersGUI%2FStdMeshersGUI_StdHypothesisCreator.cxx;fp=src%2FStdMeshersGUI%2FStdMeshersGUI_StdHypothesisCreator.cxx;h=3c0075c600a7e73b7507938b96354663b940cc80;hb=e5ed5aa5ac8420179aa37e3bf3a175e22ef3f69a;hp=f929b5ffafc53b2b5471f01706c25bfd6b643984;hpb=8bd7e4737d4999c204dba61f1c065a4611f50cce;p=modules%2Fsmesh.git diff --git a/src/StdMeshersGUI/StdMeshersGUI_StdHypothesisCreator.cxx b/src/StdMeshersGUI/StdMeshersGUI_StdHypothesisCreator.cxx index f929b5ffa..3c0075c60 100644 --- a/src/StdMeshersGUI/StdMeshersGUI_StdHypothesisCreator.cxx +++ b/src/StdMeshersGUI/StdMeshersGUI_StdHypothesisCreator.cxx @@ -39,6 +39,7 @@ // SALOME GUI includes #include +#include // IDL includes #include @@ -421,9 +422,8 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const StdMeshers::StdMeshers_LocalLength::_narrow( hypothesis() ); h->SetLength( params[0].myValue.toDouble() ); - //h->SetParameters(aVariablesList.join(":").toLatin1().constData()); h->SetPrecision( params[1].myValue.toDouble() ); - //h->SetParameters(aVariablesList.join(":").toLatin1().constData()); + getNotebook()->setParameters( h, aVariablesList ); } else if( hypType()=="MaxLength" ) { @@ -431,13 +431,13 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const StdMeshers::StdMeshers_MaxLength::_narrow( hypothesis() ); h->SetLength( params[0].myValue.toDouble() ); - //h->SetParameters(aVariablesList.join(":").toLatin1().constData()); h->SetUsePreestimatedLength( widget< QCheckBox >( 1 )->isChecked() ); if ( !h->HavePreestimatedLength() && !h->_is_equivalent( initParamsHypothesis() )) { StdMeshers::StdMeshers_MaxLength_var hInit = StdMeshers::StdMeshers_MaxLength::_narrow( initParamsHypothesis() ); h->SetPreestimatedLength( hInit->GetPreestimatedLength() ); } + getNotebook()->setParameters( h, aVariablesList ); } else if( hypType()=="SegmentLengthAroundVertex" ) { @@ -445,7 +445,7 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const StdMeshers::StdMeshers_SegmentLengthAroundVertex::_narrow( hypothesis() ); h->SetLength( params[0].myValue.toDouble() ); - //h->SetParameters(aVariablesList.join(":").toLatin1().constData()); + getNotebook()->setParameters( h, aVariablesList ); } else if( hypType()=="Arithmetic1D" ) { @@ -456,13 +456,12 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const widget< StdMeshersGUI_SubShapeSelectorWdg >( 2 ); h->SetStartLength( params[0].myValue.toDouble() ); - //h->SetParameters(aVariablesList.join(":").toLatin1().constData()); h->SetEndLength( params[1].myValue.toDouble() ); - //h->SetParameters(aVariablesList.join(":").toLatin1().constData()); if (w) { h->SetReversedEdges( w->GetListOfIDs() ); h->SetObjectEntry( w->GetMainShapeEntry() ); } + getNotebook()->setParameters( h, aVariablesList ); } else if( hypType()=="FixedPoints1D" ) { @@ -476,9 +475,9 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const widget< StdMeshersGUI_SubShapeSelectorWdg >( 1 ); if (w1) { - //h->SetParameters(aVariablesList.join(":").toLatin1().constData()); h->SetPoints( w1->GetListOfPoints() ); h->SetNbSegments( w1->GetListOfSegments() ); + getNotebook()->setParameters( h, aVariablesList ); } if (w2) { h->SetReversedEdges( w2->GetListOfIDs() ); @@ -489,8 +488,8 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const { StdMeshers::StdMeshers_MaxElementArea_var h = StdMeshers::StdMeshers_MaxElementArea::_narrow( hypothesis() ); - //h->SetParameters(aVariablesList.join(":").toLatin1().constData()); h->SetMaxElementArea( params[0].myValue.toDouble() ); + getNotebook()->setParameters( h, aVariablesList ); } else if( hypType()=="MaxElementVolume" ) { @@ -498,7 +497,7 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const StdMeshers::StdMeshers_MaxElementVolume::_narrow( hypothesis() ); h->SetMaxElementVolume( params[0].myValue.toDouble() ); - //h->SetParameters(aVariablesList.join(":").toLatin1().constData()); + getNotebook()->setParameters( h, aVariablesList ); } else if( hypType()=="StartEndLength" ) { @@ -509,20 +508,19 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const widget< StdMeshersGUI_SubShapeSelectorWdg >( 2 ); h->SetStartLength( params[0].myValue.toDouble() ); - //h->SetParameters(aVariablesList.join(":").toLatin1().constData()); h->SetEndLength( params[1].myValue.toDouble() ); - //h->SetParameters(aVariablesList.join(":").toLatin1().constData()); if (w) { h->SetReversedEdges( w->GetListOfIDs() ); h->SetObjectEntry( w->GetMainShapeEntry() ); } + getNotebook()->setParameters( h, aVariablesList ); } else if( hypType()=="Deflection1D" ) { StdMeshers::StdMeshers_Deflection1D_var h = StdMeshers::StdMeshers_Deflection1D::_narrow( hypothesis() ); - //h->SetParameters(aVariablesList.join(":").toLatin1().constData()); h->SetDeflection( params[0].myValue.toDouble() ); + getNotebook()->setParameters( h, aVariablesList ); } else if( hypType()=="AutomaticLength" ) { @@ -537,7 +535,7 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const StdMeshers::StdMeshers_NumberOfLayers::_narrow( hypothesis() ); h->SetNumberOfLayers( params[0].myValue.toInt() ); - //h->SetParameters(aVariablesList.join(":").toLatin1().constData()); + getNotebook()->setParameters( h, aVariablesList ); } else if( hypType()=="LayerDistribution" ) { @@ -547,8 +545,10 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const widget< StdMeshersGUI_LayerDistributionParamWdg >( 0 ); h->SetLayerDistribution( w->GetHypothesis() ); - //h->SetParameters(w->GetHypothesis()->GetParameters()); - //w->GetHypothesis()->ClearParameters(); + /* ouv: temporarily disabled + h->SetParameters(w->GetHypothesis()->GetParameters()); + w->GetHypothesis()->ClearParameters(); + */ } else if( hypType()=="NumberOfLayers2D" ) { @@ -556,7 +556,7 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const StdMeshers::StdMeshers_NumberOfLayers2D::_narrow( hypothesis() ); h->SetNumberOfLayers( params[0].myValue.toInt() ); - //h->SetParameters(aVariablesList.join(":").toLatin1().constData()); + getNotebook()->setParameters( h, aVariablesList ); } else if( hypType()=="LayerDistribution2D" ) { @@ -566,8 +566,10 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const widget< StdMeshersGUI_LayerDistributionParamWdg >( 0 ); h->SetLayerDistribution( w->GetHypothesis() ); - //h->SetParameters(w->GetHypothesis()->GetParameters()); - //w->GetHypothesis()->ClearParameters(); + /* ouv: temporarily disabled + h->SetParameters(w->GetHypothesis()->GetParameters()); + w->GetHypothesis()->ClearParameters(); + */ } else if( hypType()=="ProjectionSource1D" ) { @@ -653,7 +655,6 @@ bool StdMeshersGUI_StdHypothesisCreator::stdParams( ListOfStdParams& p ) const } SMESH::SMESH_Hypothesis_var hyp = initParamsHypothesis(); - //SMESH::ListOfParameters_var aParameters = hyp->GetLastParameters(); SALOME::StringArray* aParameters = hyp->GetParameters(); if( hypType()=="LocalLength" )