X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=blobdiff_plain;f=src%2FSMESHGUI%2FSMESHGUI_RotationDlg.cxx;h=85c7872d3ee9efaadb6f7b3ec44f0a9c6d093963;hp=48e7204cbac16bc01bc660abbe394a2435bd8198;hb=refs%2Ftags%2FV9_7_0b1;hpb=a17b36970bc61da1d664453c615754997c925b18 diff --git a/src/SMESHGUI/SMESHGUI_RotationDlg.cxx b/src/SMESHGUI/SMESHGUI_RotationDlg.cxx index 48e7204cb..85c7872d3 100644 --- a/src/SMESHGUI/SMESHGUI_RotationDlg.cxx +++ b/src/SMESHGUI/SMESHGUI_RotationDlg.cxx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2007-2021 CEA/DEN, EDF R&D, OPEN CASCADE // // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS @@ -287,7 +287,7 @@ SMESHGUI_RotationDlg::SMESHGUI_RotationDlg( SMESHGUI* theModule ) : myMeshOrSubMeshOrGroupFilter = new SMESH_LogicalFilter (aListOfFilters, SMESH_LogicalFilter::LO_OR); - myHelpFileName = "rotation_page.html"; + myHelpFileName = "rotation.html"; Init(); @@ -400,7 +400,7 @@ void SMESHGUI_RotationDlg::Init (bool ResetControls) //================================================================================= bool SMESHGUI_RotationDlg::ClickOnApply() { - if (mySMESHGUI->isActiveStudyLocked()) + if (SMESHGUI::isStudyLocked()) return false; if( !isValid() ) @@ -409,7 +409,7 @@ bool SMESHGUI_RotationDlg::ClickOnApply() if (myNbOkElements && IsAxisOk()) { QStringList aListElementsId = myElementsId.split(" ", QString::SkipEmptyParts); - SMESH::long_array_var anElementsId = new SMESH::long_array; + SMESH::smIdType_array_var anElementsId = new SMESH::smIdType_array; anElementsId->length(aListElementsId.count()); for (int i = 0; i < aListElementsId.count(); i++) @@ -446,13 +446,13 @@ bool SMESHGUI_RotationDlg::ClickOnApply() if(CheckBoxMesh->isChecked()) { for ( int i = 0; i < myObjects.count(); i++ ) { SMESH::SMESH_MeshEditor_var aMeshEditor = myMeshes[i]->GetMeshEditor(); - myMeshes[i]->SetParameters(aParameters.join( ":" ).toLatin1().constData()); + myMeshes[i]->SetParameters(aParameters.join( ":" ).toUtf8().constData()); aMeshEditor->RotateObject(myObjects[i], anAxis, anAngle, false); } } else { SMESH::SMESH_MeshEditor_var aMeshEditor = myMeshes[0]->GetMeshEditor(); - myMeshes[0]->SetParameters(aParameters.join( ":" ).toLatin1().constData()); + myMeshes[0]->SetParameters(aParameters.join( ":" ).toUtf8().constData()); aMeshEditor->Rotate(anElementsId, anAxis, anAngle, false); } break; @@ -462,13 +462,13 @@ bool SMESHGUI_RotationDlg::ClickOnApply() if(CheckBoxMesh->isChecked()) { for ( int i = 0; i < myObjects.count(); i++ ) { SMESH::SMESH_MeshEditor_var aMeshEditor = myMeshes[i]->GetMeshEditor(); - myMeshes[i]->SetParameters(aParameters.join( ":" ).toLatin1().constData()); + myMeshes[i]->SetParameters(aParameters.join( ":" ).toUtf8().constData()); groups = aMeshEditor->RotateObjectMakeGroups(myObjects[i], anAxis, anAngle); } } else { SMESH::SMESH_MeshEditor_var aMeshEditor = myMeshes[0]->GetMeshEditor(); - myMeshes[0]->SetParameters(aParameters.join( ":" ).toLatin1().constData()); + myMeshes[0]->SetParameters(aParameters.join( ":" ).toUtf8().constData()); groups = aMeshEditor->RotateMakeGroups(anElementsId, anAxis, anAngle); } } @@ -476,13 +476,13 @@ bool SMESHGUI_RotationDlg::ClickOnApply() if(CheckBoxMesh->isChecked()) { for ( int i = 0; i < myObjects.count(); i++ ) { SMESH::SMESH_MeshEditor_var aMeshEditor = myMeshes[i]->GetMeshEditor(); - myMeshes[i]->SetParameters(aParameters.join( ":" ).toLatin1().constData()); + myMeshes[i]->SetParameters(aParameters.join( ":" ).toUtf8().constData()); aMeshEditor->RotateObject(myObjects[i], anAxis, anAngle, true); } } else { SMESH::SMESH_MeshEditor_var aMeshEditor = myMeshes[0]->GetMeshEditor(); - myMeshes[0]->SetParameters(aParameters.join( ":" ).toLatin1().constData()); + myMeshes[0]->SetParameters(aParameters.join( ":" ).toUtf8().constData()); aMeshEditor->Rotate(anElementsId, anAxis, anAngle, true); } } @@ -493,9 +493,9 @@ bool SMESHGUI_RotationDlg::ClickOnApply() for ( int i = 0; i < myObjects.count(); i++ ) { QString aName = SMESH::UniqueMeshName( LineEditNewMesh->text().replace( "*", myObjectsNames[i] ) ); SMESH::SMESH_MeshEditor_var aMeshEditor = myMeshes[i]->GetMeshEditor(); - myMeshes[i]->SetParameters(aParameters.join( ":" ).toLatin1().constData()); + myMeshes[i]->SetParameters(aParameters.join( ":" ).toUtf8().constData()); mesh = aMeshEditor->RotateObjectMakeMesh(myObjects[i], anAxis, anAngle, makeGroups, - aName.toLatin1().data()); + aName.toUtf8().data()); if (!mesh->_is_nil()) { if( _PTR(SObject) aSObject = SMESH::ObjectToSObject( mesh ) ) anEntryList.append( aSObject->GetID().c_str() ); @@ -504,9 +504,9 @@ bool SMESHGUI_RotationDlg::ClickOnApply() } else { SMESH::SMESH_MeshEditor_var aMeshEditor = myMeshes[0]->GetMeshEditor(); - myMeshes[0]->SetParameters(aParameters.join( ":" ).toLatin1().constData()); + myMeshes[0]->SetParameters(aParameters.join( ":" ).toUtf8().constData()); mesh = aMeshEditor->RotateMakeMesh(anElementsId, anAxis, anAngle, makeGroups, - LineEditNewMesh->text().toLatin1().data()); + LineEditNewMesh->text().toUtf8().data()); if (!mesh->_is_nil()) { if( _PTR(SObject) aSObject = SMESH::ObjectToSObject( mesh ) ) anEntryList.append( aSObject->GetID().c_str() ); @@ -635,7 +635,7 @@ void SMESHGUI_RotationDlg::onTextChange (const QString& theNewText) buttonOk->setEnabled(false); buttonApply->setEnabled(false); - // hilight entered elements + // highlight entered elements SMDS_Mesh* aMesh = 0; if (myActor) aMesh = myActor->GetObject()->GetMesh(); @@ -644,7 +644,7 @@ void SMESHGUI_RotationDlg::onTextChange (const QString& theNewText) if (send == LineEditElements) { Handle(SALOME_InteractiveObject) anIO = myActor->getIO(); - TColStd_MapOfInteger newIndices; + SVTK_TVtkIDsMap newIndices; QStringList aListId = theNewText.split(" ", QString::SkipEmptyParts); for (int i = 0; i < aListId.count(); i++) { @@ -1135,7 +1135,7 @@ void SMESHGUI_RotationDlg::onDisplaySimulation( bool toDisplayPreview ) { if (myPreviewCheckBox->isChecked() && toDisplayPreview) { if(myNbOkElements && isValid() && IsAxisOk()) { QStringList aListElementsId = myElementsId.split(" ", QString::SkipEmptyParts); - SMESH::long_array_var anElementsId = new SMESH::long_array; + SMESH::smIdType_array_var anElementsId = new SMESH::smIdType_array; anElementsId->length(aListElementsId.count()); for (int i = 0; i < aListElementsId.count(); i++)