mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2025-01-13 10:10:33 +05:00
untabify
This commit is contained in:
parent
1e7cc80211
commit
4e647c5275
@ -5750,25 +5750,25 @@ bool SMESHGUI::renameObject( const QString& entry, const QString& name) {
|
|||||||
// check type to prevent renaming of inappropriate objects
|
// check type to prevent renaming of inappropriate objects
|
||||||
int aType = SMESHGUI_Selection::type( qPrintable(entry), aStudy );
|
int aType = SMESHGUI_Selection::type( qPrintable(entry), aStudy );
|
||||||
if (aType == MESH || aType == GROUP ||
|
if (aType == MESH || aType == GROUP ||
|
||||||
aType == SUBMESH || aType == SUBMESH_COMPOUND ||
|
aType == SUBMESH || aType == SUBMESH_COMPOUND ||
|
||||||
aType == SUBMESH_SOLID || aType == SUBMESH_FACE ||
|
aType == SUBMESH_SOLID || aType == SUBMESH_FACE ||
|
||||||
aType == SUBMESH_EDGE || aType == SUBMESH_VERTEX ||
|
aType == SUBMESH_EDGE || aType == SUBMESH_VERTEX ||
|
||||||
aType == HYPOTHESIS || aType == ALGORITHM) {
|
aType == HYPOTHESIS || aType == ALGORITHM) {
|
||||||
if ( !name.isEmpty() ) {
|
if ( !name.isEmpty() ) {
|
||||||
SMESHGUI::GetSMESHGen()->SetName(obj->GetIOR().c_str(), qPrintable(name) );
|
SMESHGUI::GetSMESHGen()->SetName(obj->GetIOR().c_str(), qPrintable(name) );
|
||||||
|
|
||||||
// update name of group object and its actor
|
// update name of group object and its actor
|
||||||
Handle(SALOME_InteractiveObject) IObject =
|
Handle(SALOME_InteractiveObject) IObject =
|
||||||
new SALOME_InteractiveObject ( qPrintable(entry), "SMESH", qPrintable(name) );
|
new SALOME_InteractiveObject ( qPrintable(entry), "SMESH", qPrintable(name) );
|
||||||
|
|
||||||
SMESH::SMESH_GroupBase_var aGroupObject = SMESH::IObjectToInterface<SMESH::SMESH_GroupBase>(IObject);
|
SMESH::SMESH_GroupBase_var aGroupObject = SMESH::IObjectToInterface<SMESH::SMESH_GroupBase>(IObject);
|
||||||
if( !aGroupObject->_is_nil() ) {
|
if( !aGroupObject->_is_nil() ) {
|
||||||
aGroupObject->SetName( qPrintable(name) );
|
aGroupObject->SetName( qPrintable(name) );
|
||||||
if ( SMESH_Actor *anActor = SMESH::FindActorByEntry( qPrintable(entry) ) )
|
if ( SMESH_Actor *anActor = SMESH::FindActorByEntry( qPrintable(entry) ) )
|
||||||
anActor->setName( qPrintable(name) );
|
anActor->setName( qPrintable(name) );
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user