mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2024-11-15 10:08:34 +05:00
0021327: EDF 1915 SMESH: impossible to select a group to copy mesh
trim white spaces at end of object name, else the object seems not selected
This commit is contained in:
parent
39f36db219
commit
6426baa9f3
@ -487,7 +487,8 @@ void SMESHGUI_DuplicateNodesDlg::onSelectionChanged()
|
||||
if ( myCurrentLineEdit == myLineEdit1 ) myGroups1 = aGroups;
|
||||
else if ( myCurrentLineEdit == myLineEdit2 ) myGroups2 = aGroups;
|
||||
else if ( myCurrentLineEdit == myLineEdit3 ) myGroups3 = aGroups;
|
||||
myCurrentLineEdit->setText( aGroups.count() == 1 ? aGroups[0]->GetName() :
|
||||
CORBA::String_var name = aGroups[0]->GetName();
|
||||
myCurrentLineEdit->setText( aGroups.count() == 1 ? QString(name).trimmed() :
|
||||
QObject::tr( "SMESH_OBJECTS_SELECTED" ).arg( aGroups.count() ) );
|
||||
}
|
||||
else {
|
||||
|
@ -468,7 +468,8 @@ void SMESHGUI_FindElemByPointOp::onSelectionDone()
|
||||
if ( pObj && !myMeshOrPart->_is_nil() )
|
||||
{
|
||||
myMeshIO = anIO;
|
||||
myDlg->myMeshName->setText( pObj->GetName().c_str() );
|
||||
std::string name = pObj->GetName();
|
||||
myDlg->myMeshName->setText( QString( name.c_str() ).trimmed() );
|
||||
newMeshEntry = anIO->getEntry();
|
||||
SMESH::array_of_ElementType_var types = myMeshOrPart->GetTypes();
|
||||
myDlg->setTypes( types );
|
||||
|
@ -1612,7 +1612,6 @@ void SMESHGUI_GroupDlg::onSelectGeomGroup(bool on)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//=================================================================================
|
||||
// function : setCurrentSelection()
|
||||
// purpose :
|
||||
|
@ -294,6 +294,8 @@ void SMESHGUI_Make2DFrom3DOp::selectionDone()
|
||||
QStringList names, ids;
|
||||
LightApp_Dialog::TypesList types;
|
||||
selected( names, types, ids );
|
||||
for ( int i = 0; i < names.count(); ++i )
|
||||
names[i] = names[i].trimmed();
|
||||
myDlg->selectObject( names, types, ids );
|
||||
|
||||
// enable/desable "new mesh" button
|
||||
|
@ -252,7 +252,7 @@ namespace SMESH
|
||||
int aNbSel = selected.Extent();
|
||||
if (aNbSel == 1) {
|
||||
Handle(SALOME_InteractiveObject) anIObject = selected.First();
|
||||
theName = anIObject->getName();
|
||||
theName = QString( anIObject->getName() ).trimmed();
|
||||
} else {
|
||||
theName = QObject::tr("SMESH_OBJECTS_SELECTED").arg(aNbSel);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user