+ }*/
+
+ SALOME_ListIO selObjs;
+ TColStd_IndexedMapOfInteger selIndices;
+ selectionMgr()->selectedObjects( selObjs );
+ Selection_Mode mode = selectionMode();
+ EntityType objtype = mode == NodeSelection ? MeshNode : MeshElement;
+
+ for( SALOME_ListIteratorOfListIO anIt( selObjs ); anIt.More(); anIt.Next() )
+ {
+ selIndices.Clear();
+ selectionMgr()->GetIndexes( anIt.Value(), selIndices );
+ if( selIndices.Extent() > 0 )
+ {
+ QString id_str = QString( "%1%2%3" ).arg( anIt.Value()->getEntry() ).arg( idChar() ), current_id_str;
+ for( int i=1, n=selIndices.Extent(); i<=n; i++ )
+ {
+ int curid = selIndices( i );
+ current_id_str = id_str.arg( curid );
+ ids.append( current_id_str );
+ types.append( typeById( current_id_str, objtype ) );
+ names.append( QString( "%1" ).arg( curid ) );
+ }
+ }
+ else
+ {
+ QString id = anIt.Value()->getEntry();
+ ids.append( id );
+ types.append( typeById( id, Object ) );
+ SalomeApp_Study* _study = dynamic_cast<SalomeApp_Study*>( study() );
+ if( _study )
+ {
+ _PTR(SObject) obj = _study->studyDS()->FindObjectID( anIt.Value()->getEntry() );
+ if( obj )
+ names.append( obj->GetName().c_str() );
+ }
+ }