Standard_Boolean ModuleBase_FilterValidated::IsOk(const Handle(SelectMgr_EntityOwner)& theOwner) const
{
ModuleBase_Operation* anOperation = myWorkshop->module()->currentOperation();
- ModuleBase_IPropertyPanel* aPanel = anOperation->propertyPanel();
+ if (!anOperation)
+ return true;
+ ModuleBase_IPropertyPanel* aPanel = anOperation->propertyPanel();
ModuleBase_ModelWidget* anActiveWidget = aPanel->activeWidget();
ModuleBase_WidgetValidated* aWidgetValidated = dynamic_cast<ModuleBase_WidgetValidated*>
(anActiveWidget);
//XGUI_Displayer* aDisp = myWorkshop->displayer();
//aDisp->closeLocalContexts();
erasePreviewPlanes();
+ activateFilters(myWorkshop->module()->workshop(), false);
}
void PartSet_WidgetSketchLabel::erasePreviewPlanes()
Handle(AIS_InteractiveContext) aContext = AISContext();
if (aContext.IsNull())
return;
- GetFilter()->Remove(theFilter);
+ Handle(SelectMgr_AndFilter) aCompositeFilter = GetFilter();
+ if (aCompositeFilter->IsIn(theFilter))
+ aCompositeFilter->Remove(theFilter);
}
void XGUI_Displayer::removeFilters()