X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=blobdiff_plain;f=src%2FSMESHGUI%2FSMESHGUI_RevolutionDlg.cxx;h=99309ef594774a4b198b13fcab9bd2cddef23c66;hp=82a7a0451b30c1bcecce4cbfdf92e208191a7d80;hb=d9f4b53e489dd5857db264ede6acded7b076c9f1;hpb=5482b99d07dd144fd5be299e722f39a81de3b5be diff --git a/src/SMESHGUI/SMESHGUI_RevolutionDlg.cxx b/src/SMESHGUI/SMESHGUI_RevolutionDlg.cxx index 82a7a0451..99309ef59 100644 --- a/src/SMESHGUI/SMESHGUI_RevolutionDlg.cxx +++ b/src/SMESHGUI/SMESHGUI_RevolutionDlg.cxx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2015 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2007-2022 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 @@ -57,7 +57,7 @@ #include #include #include -#include +//#include // OCCT includes #include @@ -202,13 +202,15 @@ SMESHGUI_RevolutionDlg::SMESHGUI_RevolutionDlg( SMESHGUI* theModule ) MakeGroupsCheck = new QCheckBox(tr("SMESH_MAKE_GROUPS"), GroupArguments); MakeGroupsCheck->setChecked(true); - GroupArgumentsLayout->addWidget(SelectorWdg, 0, 0, 1, 4); - GroupArgumentsLayout->addWidget(GroupAxis, 1, 0, 1, 4); - GroupArgumentsLayout->addWidget(GroupAngleBox, 2, 0, 1, 4); - GroupArgumentsLayout->addWidget(TextLabelTolerance, 3, 0, 1, 2); - GroupArgumentsLayout->addWidget(SpinBox_Tolerance, 3, 2, 1, 2); - GroupArgumentsLayout->addWidget(myPreviewCheckBox, 4, 0, 1, 4); - GroupArgumentsLayout->addWidget(MakeGroupsCheck, 5, 0, 1, 4); + GroupArgumentsLayout->addWidget(SelectorWdg, 0, 0, 3, 4); + GroupArgumentsLayout->addWidget(GroupAxis, 0, 4, 1, 4); + GroupArgumentsLayout->addWidget(GroupAngleBox, 1, 4, 1, 4); + GroupArgumentsLayout->addWidget(TextLabelTolerance, 2, 4, 1, 2); + GroupArgumentsLayout->addWidget(SpinBox_Tolerance, 2, 6, 1, 2); + GroupArgumentsLayout->addWidget(myPreviewCheckBox, 3, 0, 1, 2); + GroupArgumentsLayout->addWidget(MakeGroupsCheck, 3, 2, 1, 2); + SelectorWdg->setSizePolicy(QSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding)); + SelectorWdg->setMinimumWidth(320); SelectorWdg->GetButtonGroup()->addButton( SelectVectorButton ); SelectorWdg->GetButtonGroup()->addButton( SelectPointButton ); @@ -261,7 +263,7 @@ SMESHGUI_RevolutionDlg::SMESHGUI_RevolutionDlg( SMESHGUI* theModule ) mySMESHGUI->SetActiveDialogBox((QDialog*)this); - myHelpFileName = "revolution_page.html"; + myHelpFileName = "revolution.html"; Init(); @@ -392,7 +394,7 @@ bool SMESHGUI_RevolutionDlg::isValid() //================================================================================= bool SMESHGUI_RevolutionDlg::ClickOnApply() { - if (mySMESHGUI->isActiveStudyLocked()) + if (SMESHGUI::isStudyLocked()) return false; if (!isValid()) @@ -436,7 +438,7 @@ bool SMESHGUI_RevolutionDlg::ClickOnApply() SMESH::SMESH_Mesh_var mesh = SelectorWdg->GetMesh(); - mesh->SetParameters( aParameters.join(":").toLatin1().constData() ); + mesh->SetParameters( aParameters.join(":").toUtf8().constData() ); SMESH::ListOfIDSources_var nodes = new SMESH::ListOfIDSources(); SMESH::ListOfIDSources_var edges = new SMESH::ListOfIDSources(); @@ -573,7 +575,7 @@ void SMESHGUI_RevolutionDlg::ClickOnHelp() // function : onAngleTextChange() // purpose : //======================================================================= -void SMESHGUI_RevolutionDlg::onAngleTextChange (const QString& theNewText) +void SMESHGUI_RevolutionDlg::onAngleTextChange (const QString& /*theNewText*/) { bool isNumber; SpinBox_Angle->text().toDouble( &isNumber ); @@ -602,7 +604,7 @@ void SMESHGUI_RevolutionDlg::SelectionIntoArgument() return; Handle(SALOME_InteractiveObject) IO = aList.First(); - TColStd_IndexedMapOfInteger aMapIndex; + SVTK_TIndexedMapOfVtkId aMapIndex; mySelector->GetIndex(IO,aMapIndex); if ( aMapIndex.Extent() != 1 ) return; @@ -641,7 +643,7 @@ void SMESHGUI_RevolutionDlg::SelectionIntoArgument() else if ( isFaceSelected ) { const SMDS_MeshFace* face = - dynamic_cast(aMesh->FindElement(aMapIndex(1))); + SMDS_Mesh::DownCast( aMesh->FindElement( aMapIndex( 1 ))); if (!face) return; gp_XYZ aNormale = SMESH::getNormale(face); @@ -796,7 +798,7 @@ void SMESHGUI_RevolutionDlg::onDisplaySimulation(bool toDisplayPreview) anAxis, anAngle, aNbSteps, aTolerance, makeGroups ); SMESH::MeshPreviewStruct_var aMeshPreviewStruct = meshEditor->GetPreviewData(); - mySimulation->SetData( aMeshPreviewStruct._retn() ); + mySimulation->SetData( aMeshPreviewStruct.in() ); } catch (...) {} }