Salome HOME
Remove JoinObjectParameters() function
authorvsr <vsr@opencascade.com>
Wed, 30 Sep 2009 08:10:20 +0000 (08:10 +0000)
committervsr <vsr@opencascade.com>
Wed, 30 Sep 2009 08:10:20 +0000 (08:10 +0000)
17 files changed:
src/SMESHGUI/SMESHGUI.cxx
src/SMESHGUI/SMESHGUI.h
src/SMESHGUI/SMESHGUI_BuildCompoundDlg.cxx
src/SMESHGUI/SMESHGUI_ExtrusionAlongPathDlg.cxx
src/SMESHGUI/SMESHGUI_ExtrusionDlg.cxx
src/SMESHGUI/SMESHGUI_MakeNodeAtPointDlg.cxx
src/SMESHGUI/SMESHGUI_MeshPatternDlg.cxx
src/SMESHGUI/SMESHGUI_MoveNodesDlg.cxx
src/SMESHGUI/SMESHGUI_MultiEditDlg.cxx
src/SMESHGUI/SMESHGUI_NodesDlg.cxx
src/SMESHGUI/SMESHGUI_RevolutionDlg.cxx
src/SMESHGUI/SMESHGUI_RotationDlg.cxx
src/SMESHGUI/SMESHGUI_SmoothingDlg.cxx
src/SMESHGUI/SMESHGUI_SymmetryDlg.cxx
src/SMESHGUI/SMESHGUI_TranslationDlg.cxx
src/StdMeshersGUI/StdMeshersGUI_NbSegmentsCreator.cxx
src/StdMeshersGUI/StdMeshersGUI_StdHypothesisCreator.cxx

index 4b41c1d20a1b0765ea66e5f0d953f5c4c599996f..66aefe0e2a51f0b182030d53f259ab96477796f9 100644 (file)
@@ -1294,16 +1294,6 @@ SalomeApp_Study* SMESHGUI::activeStudy()
     return NULL;
 }
 
-//=============================================================================
-/*!
- *
- */
-//=============================================================================
-char* SMESHGUI::JoinObjectParameters(const QStringList& theParametersList)
-{
-  return theParametersList.join(":").toLatin1().data();
-}
-
 //=============================================================================
 /*!
  *
index 23af4d0e29b541697ff4510af8bb4dd8ab1a33b1..f162f88ccd7ece67c0c34c8f467b98a6e1d50226 100644 (file)
@@ -70,7 +70,6 @@ public :
   static SUIT_ResourceMgr*        resourceMgr();
   static SUIT_Desktop*            desktop();
   static SalomeApp_Study*         activeStudy();
-  static char*                    JoinObjectParameters(const QStringList& theParametersList);
   
   bool                            isActiveStudyLocked();
 
index 2d6b7435bfb7dbc0b048ddf0f0a4495e9904e29a..3ec453d0b21ffcd44e71f58bfd9f1eba7b00f6a7 100644 (file)
@@ -309,7 +309,7 @@ bool SMESHGUI_BuildCompoundDlg::ClickOnApply()
                                               CheckBoxMerge->isChecked(), 
                                               SpinBoxTol->GetValue());
      
-      aCompoundMesh->SetParameters( SMESHGUI::JoinObjectParameters(aParameters) );
+      aCompoundMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
 
       SMESH::SetName( SMESH::FindSObject( aCompoundMesh ), LineEditName->text() );
       mySMESHGUI->updateObjBrowser();
index 8d1d9c300495462cc4eb31d76c81c8da8e94e78a..c683010169be7a20c00dbe1afb89ea4fead156e6 100644 (file)
@@ -621,7 +621,7 @@ bool SMESHGUI_ExtrusionAlongPathDlg::ClickOnApply()
 
 
     if( retVal == SMESH::SMESH_MeshEditor::EXTR_OK )
-      myMesh->SetParameters( SMESHGUI::JoinObjectParameters(aParameters) );
+      myMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
 
     //wc.stop();
     wc.suspend();
index 2ed9123835b509ec3bde2c6d902449c572bd2f66..beb2e3f24b17c3f2e4f9a7f3dc7244f1077083ea 100644 (file)
@@ -558,7 +558,7 @@ bool SMESHGUI_ExtrusionDlg::ClickOnApply()
          aMeshEditor->ExtrusionSweep(myElementsId.inout(), aVector, aNbSteps);
       }
 
-      myMesh->SetParameters( SMESHGUI::JoinObjectParameters(aParameters) );
+      myMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
 
     } catch (...) {
     }
index 9fbdc9df0b9a21b8df3020cf60518e1258232a1a..a2c4f176324fad3c23d189cddd9fa76c4e28128f 100644 (file)
@@ -414,7 +414,7 @@ bool SMESHGUI_MakeNodeAtPointOp::onApply()
       aParameters << myDlg->myX->text();
       aParameters << myDlg->myY->text();
       aParameters << myDlg->myZ->text();
-      aMesh->SetParameters( SMESHGUI::JoinObjectParameters(aParameters) );
+      aMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
 
       myDlg->myId->setText("");
 
index 820b2ec91e8b08caa1c2f7704082165ae8f63ace..36a739f75ca1904b658e0ed71b5901a9fa3eaf52 100755 (executable)
@@ -482,7 +482,7 @@ bool SMESHGUI_MeshPatternDlg::onApply()
       aParameters << myNode1->text();
       if(myType == Type_3d )
        aParameters << myNode2->text();
-      myMesh->SetParameters( SMESHGUI::JoinObjectParameters(aParameters) );
+      myMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
 
     } else { // Applying a pattern to geometrical object
       if (myType == Type_2d)
index 199575293198380fc5a22b6bd78b8a599bf17564..ecd46ea8872ad561b8c9bb60a250c08a24fe3374 100644 (file)
@@ -346,7 +346,7 @@ bool SMESHGUI_MoveNodesDlg::onApply()
     aParameters << myX->text();
     aParameters << myY->text();
     aParameters << myZ->text();
-    aMesh->SetParameters( SMESHGUI::JoinObjectParameters(aParameters) );
+    aMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
   } catch (...) {
   }
 
index 526c3f3e3ea8c5a492396320e96784aeae6deb7d..f26b81c5b40adb586ff1fa02312442487fbd2a07 100755 (executable)
@@ -1198,7 +1198,7 @@ bool SMESHGUI_UnionOfTrianglesDlg::process (SMESH::SMESH_MeshEditor_ptr theEdito
   if( ok ) {
     QStringList aParameters;
     aParameters << myMaxAngleSpin->text();
-    myMesh->SetParameters( SMESHGUI::JoinObjectParameters(aParameters) );
+    myMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
   }
   return ok;
 }
index ff98cb7f8441f113bc0a9b8c5016d33788603f5a..76b75dbb9139c5a924b33baa70166ffe2724a853 100644 (file)
@@ -95,7 +95,7 @@ namespace SMESH
       _PTR(SObject) aSobj = SMESH::FindSObject( theMesh );
       SMESH::SMESH_MeshEditor_var aMeshEditor = theMesh->GetMeshEditor();
       aMeshEditor->AddNode( x, y, z );
-      theMesh->SetParameters( SMESHGUI::JoinObjectParameters(theParameters) );
+      theMesh->SetParameters( theParameters.join(":").toLatin1().constData() );
       _PTR(Study) aStudy = GetActiveStudyDocument();
       CORBA::Long anId = aStudy->StudyId();
       if (TVisualObjPtr aVisualObj = SMESH::GetVisualObj( anId, aSobj->GetID().c_str() ) ) {
index e9e7fef05a8442748dc152179f3791b08db409a3..27096123600d6c2d8fc38a198dec8d83d5c78736 100644 (file)
@@ -544,7 +544,7 @@ bool SMESHGUI_RevolutionDlg::ClickOnApply()
          aMeshEditor->RotationSweep(anElementsId.inout(), anAxis, anAngle, aNbSteps, aTolerance);
       }
 
-      myMesh->SetParameters( SMESHGUI::JoinObjectParameters(aParameters) );
+      myMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
     } catch (...) {
     }
 
index 4f122537b7d6a641f2946e991baf0883f5d9ee7e..a148af80eb8f7bd55eb692f52b9b92e9f883f80f 100644 (file)
@@ -415,7 +415,7 @@ bool SMESHGUI_RotationDlg::ClickOnApply()
         else
             aMeshEditor->Rotate(anElementsId, anAxis, anAngle, false);
        if( !myMesh->_is_nil())
-         myMesh->SetParameters(SMESHGUI::JoinObjectParameters(aParameters));
+         myMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
         break;
       case COPY_ELEMS_BUTTON:
         if ( makeGroups ) {
@@ -432,7 +432,7 @@ bool SMESHGUI_RotationDlg::ClickOnApply()
             aMeshEditor->Rotate(anElementsId, anAxis, anAngle, true);
         }
        if( !myMesh->_is_nil())
-         myMesh->SetParameters(SMESHGUI::JoinObjectParameters(aParameters));
+         myMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
         break;
       case MAKE_MESH_BUTTON:
         SMESH::SMESH_Mesh_var mesh;
@@ -443,7 +443,7 @@ bool SMESHGUI_RotationDlg::ClickOnApply()
           mesh = aMeshEditor->RotateMakeMesh(anElementsId, anAxis, anAngle, makeGroups,
                                              LineEditNewMesh->text().toLatin1().data());
        if( !mesh->_is_nil())
-         mesh->SetParameters(SMESHGUI::JoinObjectParameters(aParameters));
+         mesh->SetParameters( aParameters.join(":").toLatin1().constData() );
       }
     } catch (...) {
     }
index 9112c56d012fdbfdd23a3fd72a8a37155c171e71..d824e32ac0e065b3a0f37c97868446108bc559f9 100644 (file)
@@ -380,7 +380,7 @@ bool SMESHGUI_SmoothingDlg::ClickOnApply()
                                        anIterationLimit, aMaxAspectRatio, aMethod);
       }
 
-      myMesh->SetParameters( SMESHGUI::JoinObjectParameters(aParameters) );
+      myMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
 
     } catch (...) {
     }
index a7c0cbaae36ff4bca4a38d375938ba03db75e333..d66f82f6ee22d3b0d441dfda85765bf39f414819 100644 (file)
@@ -500,7 +500,7 @@ bool SMESHGUI_SymmetryDlg::ClickOnApply()
           aMeshEditor->Mirror(anElementsId, aMirror, aMirrorType, false );
         
        if( !myMesh->_is_nil())
-         myMesh->SetParameters(SMESHGUI::JoinObjectParameters(aParameters));
+         myMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
         break;
       }
       case COPY_ELEMS_BUTTON: {
@@ -518,7 +518,7 @@ bool SMESHGUI_SymmetryDlg::ClickOnApply()
             aMeshEditor->Mirror(anElementsId, aMirror, aMirrorType, true);
         }
        if( !myMesh->_is_nil())
-         myMesh->SetParameters(SMESHGUI::JoinObjectParameters(aParameters));
+         myMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
         break;
         }
       case MAKE_MESH_BUTTON: {
@@ -530,7 +530,7 @@ bool SMESHGUI_SymmetryDlg::ClickOnApply()
           mesh = aMeshEditor->MirrorMakeMesh(anElementsId, aMirror, aMirrorType, makeGroups,
                                              LineEditNewMesh->text().toLatin1().data());
        if( !mesh->_is_nil())
-         mesh->SetParameters(SMESHGUI::JoinObjectParameters(aParameters));
+         mesh->SetParameters( aParameters.join(":").toLatin1().constData() );
         break;
       }
       }
index 757c34b8f3489947753c20542a9911a7f0c0db98..6956cc9fb63a08ee1f892a31eb9d81c56cccff7b 100644 (file)
@@ -488,7 +488,7 @@ bool SMESHGUI_TranslationDlg::ClickOnApply()
         else
           aMeshEditor->Translate(anElementsId, aVector, false);
        if( !myMesh->_is_nil())
-         myMesh->SetParameters(SMESHGUI::JoinObjectParameters(aParameters));
+         myMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
         break;
       case COPY_ELEMS_BUTTON:
         if ( makeGroups ) {
@@ -505,7 +505,7 @@ bool SMESHGUI_TranslationDlg::ClickOnApply()
             aMeshEditor->Translate(anElementsId, aVector, true);
         }
        if( !myMesh->_is_nil())
-         myMesh->SetParameters(SMESHGUI::JoinObjectParameters(aParameters));
+         myMesh->SetParameters( aParameters.join(":").toLatin1().constData() );
         break;
       case MAKE_MESH_BUTTON:
         SMESH::SMESH_Mesh_var mesh; 
@@ -516,7 +516,7 @@ bool SMESHGUI_TranslationDlg::ClickOnApply()
           mesh = aMeshEditor->TranslateMakeMesh(anElementsId, aVector, makeGroups,
                                                 LineEditNewMesh->text().toLatin1().data());
        if( !mesh->_is_nil())
-         mesh->SetParameters(SMESHGUI::JoinObjectParameters(aParameters));
+         mesh->SetParameters( aParameters.join(":").toLatin1().constData() );
       }
     } catch (...) {
     }
index 50906a0cad09c12727115067f295b1411158df23..2ee5473af34992aee5ac4cc34109832b0a7490d9 100644 (file)
@@ -379,7 +379,7 @@ bool StdMeshersGUI_NbSegmentsCreator::storeParamsToHypo( const NbSegmentsHypothe
     //the function will be checked with old conversion mode, so that it may occurs
     //unexpected errors for user
 
-    h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+    h->SetParameters(aVariablesList.join(":").toLatin1().constData());
   }
   catch(const SALOME::SALOME_Exception& ex)
   {
index a377b80280592cb9622a42ba924b47a0f5fb4444..690507e214fdb56a7cdb5bccd27e78604fb8a5f5 100644 (file)
@@ -415,9 +415,9 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const
         StdMeshers::StdMeshers_LocalLength::_narrow( hypothesis() );
 
       h->SetLength( params[0].myValue.toDouble() );
-      h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+      h->SetParameters(aVariablesList.join(":").toLatin1().constData());
       h->SetPrecision( params[1].myValue.toDouble() );
-      h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+      h->SetParameters(aVariablesList.join(":").toLatin1().constData());
     }
     else if( hypType()=="MaxLength" )
     {
@@ -425,7 +425,7 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const
         StdMeshers::StdMeshers_MaxLength::_narrow( hypothesis() );
 
       h->SetLength( params[0].myValue.toDouble() );
-      h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+      h->SetParameters(aVariablesList.join(":").toLatin1().constData());
       h->SetUsePreestimatedLength( widget< QCheckBox >( 1 )->isChecked() );
       if ( !h->HavePreestimatedLength() && !h->_is_equivalent( initParamsHypothesis() )) {
         StdMeshers::StdMeshers_MaxLength_var hInit =
@@ -439,7 +439,7 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const
         StdMeshers::StdMeshers_SegmentLengthAroundVertex::_narrow( hypothesis() );
 
       h->SetLength( params[0].myValue.toDouble() );
-      h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+      h->SetParameters(aVariablesList.join(":").toLatin1().constData());
     }
     else if( hypType()=="Arithmetic1D" )
     {
@@ -450,9 +450,9 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const
         widget< StdMeshersGUI_SubShapeSelectorWdg >( 2 );
 
       h->SetStartLength( params[0].myValue.toDouble() );
-      h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+      h->SetParameters(aVariablesList.join(":").toLatin1().constData());
       h->SetEndLength( params[1].myValue.toDouble() );
-      h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+      h->SetParameters(aVariablesList.join(":").toLatin1().constData());
       if (w) {
         h->SetReversedEdges( w->GetListOfIDs() );
         h->SetObjectEntry( w->GetMainShapeEntry() );
@@ -470,7 +470,7 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const
         widget< StdMeshersGUI_SubShapeSelectorWdg >( 1 );
 
       if (w1) {
-        h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+        h->SetParameters(aVariablesList.join(":").toLatin1().constData());
         h->SetPoints( w1->GetListOfPoints() );
         h->SetNbSegments( w1->GetListOfSegments() );
       }
@@ -483,7 +483,7 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const
     {
       StdMeshers::StdMeshers_MaxElementArea_var h =
         StdMeshers::StdMeshers_MaxElementArea::_narrow( hypothesis() );
-      h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+      h->SetParameters(aVariablesList.join(":").toLatin1().constData());
       h->SetMaxElementArea( params[0].myValue.toDouble() );
     }
     else if( hypType()=="MaxElementVolume" )
@@ -492,7 +492,7 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const
         StdMeshers::StdMeshers_MaxElementVolume::_narrow( hypothesis() );
 
       h->SetMaxElementVolume( params[0].myValue.toDouble() );
-      h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+      h->SetParameters(aVariablesList.join(":").toLatin1().constData());
     }
     else if( hypType()=="StartEndLength" )
     {
@@ -503,9 +503,9 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const
         widget< StdMeshersGUI_SubShapeSelectorWdg >( 2 );
 
       h->SetStartLength( params[0].myValue.toDouble() );
-      h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+      h->SetParameters(aVariablesList.join(":").toLatin1().constData());
       h->SetEndLength( params[1].myValue.toDouble() );
-      h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+      h->SetParameters(aVariablesList.join(":").toLatin1().constData());
       if (w) {
         h->SetReversedEdges( w->GetListOfIDs() );
         h->SetObjectEntry( w->GetMainShapeEntry() );
@@ -515,7 +515,7 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const
     {
       StdMeshers::StdMeshers_Deflection1D_var h =
         StdMeshers::StdMeshers_Deflection1D::_narrow( hypothesis() );
-      h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+      h->SetParameters(aVariablesList.join(":").toLatin1().constData());
       h->SetDeflection( params[0].myValue.toDouble() );
     }
     else if( hypType()=="AutomaticLength" )
@@ -531,7 +531,7 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const
         StdMeshers::StdMeshers_NumberOfLayers::_narrow( hypothesis() );
 
       h->SetNumberOfLayers( params[0].myValue.toInt() );
-      h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+      h->SetParameters(aVariablesList.join(":").toLatin1().constData());
     }
     else if( hypType()=="LayerDistribution" )
     {
@@ -550,7 +550,7 @@ QString StdMeshersGUI_StdHypothesisCreator::storeParams() const
         StdMeshers::StdMeshers_NumberOfLayers2D::_narrow( hypothesis() );
 
       h->SetNumberOfLayers( params[0].myValue.toInt() );
-      h->SetParameters(SMESHGUI::JoinObjectParameters(aVariablesList));
+      h->SetParameters(aVariablesList.join(":").toLatin1().constData());
     }
     else if( hypType()=="LayerDistribution2D" )
     {
@@ -878,7 +878,7 @@ bool StdMeshersGUI_StdHypothesisCreator::stdParams( ListOfStdParams& p ) const
       aLastVarsList.append(QString(aParameters[i].in()));
 
     if(!aLastVarsList.isEmpty())
-      h->GetLayerDistribution()->SetLastParameters(SMESHGUI::JoinObjectParameters(aLastVarsList));
+      h->GetLayerDistribution()->SetLastParameters(aLastVarsList.join(":").toLatin1().constData());
     
     customWidgets()->append
       ( new StdMeshersGUI_LayerDistributionParamWdg( h->GetLayerDistribution(), hypName(), dlg()));
@@ -904,7 +904,7 @@ bool StdMeshersGUI_StdHypothesisCreator::stdParams( ListOfStdParams& p ) const
       aLastVarsList.append(QString(aParameters[i].in()));
 
     if(!aLastVarsList.isEmpty())
-      h->GetLayerDistribution()->SetLastParameters(SMESHGUI::JoinObjectParameters(aLastVarsList));
+      h->GetLayerDistribution()->SetLastParameters(aLastVarsList.join(":").toLatin1().constData());
     
     customWidgets()->append
       ( new StdMeshersGUI_LayerDistributionParamWdg( h->GetLayerDistribution(), hypName(), dlg()));