-
-
ModuleBase_ResultPrs::ModuleBase_ResultPrs(ResultPtr theResult)
: ViewerData_AISShape(TopoDS_Shape()), myResult(theResult), myAdditionalSelectionPriority(0)
{
anOwner = theOwners.Value(i);
aCompOwner = Handle(ModuleBase_BRepOwner)::DownCast(anOwner);
if (aCompOwner.IsNull()) {
- // PORTING_TO_SALOME_8
- //anOwner->Hilight(thePM);
+ thePM->Color(anOwner->Selectable(), GetContext()->SelectionStyle());
}
else {
TopoDS_Shape aShape = aCompOwner->Shape();
StdPrs_WFShape::Add(aSelectionPrs, aShape, myDrawer);
aSelectionPrs->SetDisplayPriority(9);
- // PORTING_TO_SALOME_8
- //aSelectionPrs->Highlight(Aspect_TOHM_COLOR, aSelectionPrs->HighlightColor());
+ aSelectionPrs->Highlight(GetContext()->SelectionStyle());
aSelectionPrs->Display();
- // PORTING_TO_SALOME_8
- //thePM->Highlight(this);
+ thePM->Color(this, GetContext()->SelectionStyle());
}
}
}
void ModuleBase_ResultPrs::HilightOwnerWithColor(const Handle(PrsMgr_PresentationManager3d)& thePM,
- const Quantity_NameOfColor theColor,
+ const Handle(Graphic3d_HighlightStyle)& theStyle,
const Handle(SelectMgr_EntityOwner)& theOwner)
{
- // PORTING_TO_SALOME_8
- /*
Handle(StdSelect_BRepOwner) aOwner = Handle(StdSelect_BRepOwner)::DownCast(theOwner);
if (aOwner.IsNull())
return;
TopoDS_Shape aShape = aOwner->Shape();
if (!aShape.IsNull()) {
- thePM->Color(this, theColor);
+ thePM->Color(this, theStyle);
Handle( Prs3d_Presentation ) aHilightPrs = GetHilightPresentation( thePM );
aHilightPrs->Clear();
StdPrs_WFShape::Add(aHilightPrs, aShape, myDrawer);
- aHilightPrs->Highlight(Aspect_TOHM_COLOR, theColor);
+ aHilightPrs->Highlight(theStyle);
if (thePM->IsImmediateModeOn())
thePM->AddToImmediateList(aHilightPrs);
- }*/
+ }
}
//! Method which hilight an owner belonging to
//! this selectable object ( for fast presentation draw )
Standard_EXPORT virtual void HilightOwnerWithColor(
- const Handle(PrsMgr_PresentationManager3d)& thePM,
- const Quantity_NameOfColor theColor, const Handle(SelectMgr_EntityOwner)& theOwner);
+ const Handle(PrsMgr_PresentationManager3d)& thePM,
+ const Handle(Graphic3d_HighlightStyle)& theStyle,
+ const Handle(SelectMgr_EntityOwner)& theOwner);
/// Returns result object
Standard_EXPORT ResultPtr getResult() const { return myResult; }