]> SALOME platform Git repositories - modules/geom.git/commitdiff
Salome HOME
Adapting for OCCT dev (7.5)
authorvsr <vsr@opencascade.com>
Thu, 19 Mar 2020 11:25:13 +0000 (14:25 +0300)
committervsr <vsr@opencascade.com>
Thu, 19 Mar 2020 11:25:13 +0000 (14:25 +0300)
src/CurveCreator/CurveCreator_Utils.cxx
src/GEOMGUI/GEOMGUI_OCCSelector.cxx
src/OBJECT/GEOM_AISShape.cxx

index 4aac8b87f2af3240af0206be40454866206fd51b..c0123f7e33addc52023742662551551b58cbcc84 100644 (file)
@@ -620,15 +620,17 @@ void CurveCreator_Utils::setSelectedPoints( Handle(AIS_InteractiveContext) theCo
   theContext->SetAutomaticHilight( Standard_False );
 
   Handle(SelectMgr_Selection) aSelection = anAISShape->Selection( AIS_Shape::SelectionMode( TopAbs_VERTEX ) );
+  const NCollection_Vector<Handle(SelectMgr_SensitiveEntity)>& selected = aSelection->Entities();
 
   CurveCreator_ICurve::SectionToPointList::const_iterator anIt = thePoints.begin(),
                                                           aLast = thePoints.end();
   bool isFound = false;
   for( int i=0; i<aSize; i++ )
   {
-  for( aSelection->Init(); aSelection->More(); aSelection->Next() )
+  for ( NCollection_Vector<Handle(SelectMgr_SensitiveEntity)>::Iterator selIter( selected );
+        selIter.More(); selIter.Next() )
   {    
-    const Handle(SelectMgr_SensitiveEntity) aHSenEntity = aSelection->Sensitive();
+    const Handle(SelectMgr_SensitiveEntity) aHSenEntity = selIter.Value();
     if( aHSenEntity.IsNull() )
       continue;
     Handle(SelectBasics_SensitiveEntity) aSenEntity = aHSenEntity->BaseSensitive();
index 1be9d93118eadd7ca774054f0adc148914a30572..b4971833c113b2660696d8ffcb721889d88f7b54 100644 (file)
@@ -178,9 +178,10 @@ static void getEntityOwners( const Handle(AIS_InteractiveObject)& theObj,
       continue;
 
     Handle(SelectMgr_Selection) sel = theObj->Selection( m );
-
-    for ( sel->Init(); sel->More(); sel->Next() ) {
-      const Handle(SelectMgr_SensitiveEntity) aHSenEntity = sel->Sensitive();
+    const NCollection_Vector<Handle(SelectMgr_SensitiveEntity)>& selected = sel->Entities();
+    for ( NCollection_Vector<Handle(SelectMgr_SensitiveEntity)>::Iterator selIter( selected );
+         selIter.More(); selIter.Next() ) {
+      const Handle(SelectMgr_SensitiveEntity) aHSenEntity = selIter.Value();
       if( aHSenEntity.IsNull() )
         continue;
 
index abfab4f731d4ff7e651a78f362bc50fc0edced4c..956327ed63aeb8b32e079ae6748bae0ba69d674d 100644 (file)
@@ -99,9 +99,10 @@ static void getEntityOwners( const Handle(AIS_InteractiveObject)&  theObj,
       continue;
 
     Handle(SelectMgr_Selection) sel = theObj->Selection( m );
-
-    for ( sel->Init(); sel->More(); sel->Next() ) {
-      const Handle(SelectMgr_SensitiveEntity) aHSenEntity = sel->Sensitive();
+    const NCollection_Vector<Handle(SelectMgr_SensitiveEntity)>& selected = sel->Entities();
+    for ( NCollection_Vector<Handle(SelectMgr_SensitiveEntity)>::Iterator selIter( selected );
+         selIter.More(); selIter.Next() ) {
+      const Handle(SelectMgr_SensitiveEntity) aHSenEntity = selIter.Value();
       if( aHSenEntity.IsNull() )
         continue;