bool SMDS_MeshGroup::Contains(const SMDS_MeshElement * theElem) const
{
- return myElements.find(theElem)!=myElements.end();
+ return myElements.find(theElem) != myElements.end();
}
//=======================================================================
//=============================================================================
/*!
- *
+ * Don't use it!
*/
//=============================================================================
virtual SMDS_ElemIteratorPtr GetElements() const = 0;
virtual int GetID (const int theIndex);
- // use it for iterations 1..Extent()
+ // DON'T use it for iterations 1..Extent()
virtual int GetTic() const = 0;
}
if (entityType()) {
- if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))
- aViewWindow->SetSelectionMode(VolumeSelection);
SMESH::SetFilter(new SMESHGUI_VolumesFilter());
- } else {
if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))
- aViewWindow->SetSelectionMode(FaceSelection);
+ aViewWindow->SetSelectionMode(VolumeSelection); // here myActor set to a filter
+ } else {
if (myFilterType == SMESH::TriaFilter)
SMESH::SetFilter(new SMESHGUI_TriangleFilter());
else if (myFilterType == SMESH::QuadFilter)
SMESH::SetFilter(new SMESHGUI_QuadrangleFilter());
else
SMESH::SetFilter(new SMESHGUI_FacesFilter());
+ if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))
+ aViewWindow->SetSelectionMode(FaceSelection); // here myActor set to a filter
}
}
{
int aSize = aGroupDS->Extent();
aRes->length(aSize);
- for (int i = 0; i < aSize; i++)
- aRes[i] = aGroupDS->GetID(i+1);
+ SMDS_ElemIteratorPtr it = aGroupDS->GetElements();
+ for (int i = 0; it->more(); i++)
+ aRes[i] = it->next()->GetID();
if ( 0 < aSize && aSize < 100 ) // for comfortable testing ;)
std::sort( &aRes[0], &aRes[0]+aSize );