blob: 8b33c0aa1a0f65c44873c8a892225cc22d79e5be (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
// File: AIS_TypeFilter.cxx
// Created: Thu Mar 6 16:59:32 1997
// Author: Robert COUBLANC
// <rob@robox.paris1.matra-dtv.fr>
#include <AIS_TypeFilter.ixx>
#include <AIS_InteractiveObject.hxx>
AIS_TypeFilter::AIS_TypeFilter(const AIS_KindOfInteractive TheKind):
myKind(TheKind){}
Standard_Boolean AIS_TypeFilter::IsOk(const Handle(SelectMgr_EntityOwner)& anObj) const
{
if(Handle(AIS_InteractiveObject)::DownCast(anObj->Selectable()).IsNull())
return Standard_False;
//#ifndef DEB
Handle_SelectMgr_SelectableObject aSelectableObject = anObj->Selectable() ;
return ((Handle(AIS_InteractiveObject)&) aSelectableObject)->Type()== myKind;
//#else
// return ((Handle(AIS_InteractiveObject)&)anObj->Selectable())->Type()== myKind;
//#endif
}
|