]> OCCT Git - occt-copy.git/commitdiff
0030737: Visualization - implementing new selection schemes in context
authorage <age@opencascade.com>
Tue, 24 Nov 2020 13:14:19 +0000 (16:14 +0300)
committerage <age@opencascade.com>
Tue, 24 Nov 2020 13:14:19 +0000 (16:14 +0300)
Fixed selections filters

src/AIS/AIS_Selection.cxx

index 10b14103674fa073fea50236a89ec46aedc09e75..e310e8df96f7c4a80bd99053b5643281f6ef51a2 100644 (file)
@@ -183,7 +183,7 @@ void AIS_Selection::SelectOwners (const AIS_NListOfEntityOwner& thePickedOwners,
         const Handle(SelectMgr_EntityOwner)& anOwner = aSelIter.Value();
         if (anOwner.IsNull()
         || !anOwner->HasSelectable()
-        || !theFilter->IsOk (anOwner))
+        || !theFilter->IsOk (anOwner, SelectMgr_FilterReaction_Select))
         {
           continue;
         }
@@ -238,7 +238,7 @@ AIS_SelectStatus AIS_Selection::appendOwner (const Handle(SelectMgr_EntityOwner)
 {
   if (theOwner.IsNull()
   || !theOwner->HasSelectable()
-  || !theFilter->IsOk (theOwner))
+  || !theFilter->IsOk (theOwner, SelectMgr_FilterReaction_Select))
   {
     return AIS_SS_NotDone;
   }
@@ -254,7 +254,7 @@ AIS_SelectStatus AIS_Selection::XOROwner (const Handle(SelectMgr_EntityOwner)& t
                                           const AIS_NListOfEntityOwner& thePreviousSelected,
                                           const Handle(SelectMgr_Filter)& theFilter)
 {
-  if (theOwner.IsNull() || !theOwner->HasSelectable() || !theFilter->IsOk (theOwner))
+  if (theOwner.IsNull() || !theOwner->HasSelectable() || !theFilter->IsOk (theOwner, SelectMgr_FilterReaction_Select))
     return AIS_SS_NotDone;
 
   if (thePreviousSelected.Contains (theOwner)) // was selected, should not be now