Salome HOME
Merge remote-tracking branch 'origin/BR_REENTRANCE_OPERATION' into origin_Dev_1.5.0
[modules/shaper.git] / src / ModuleBase / ModuleBase_FilterValidated.cpp
index a1b9bdb94e5c5ea7b180584410a95a904f43a5c0..08314d734cc3cf2793e3e601ac6a9a53d891551d 100644 (file)
@@ -23,11 +23,11 @@ Standard_Boolean ModuleBase_FilterValidated::IsOk(const Handle(SelectMgr_EntityO
   ModuleBase_Operation* anOperation = myWorkshop->module()->currentOperation();
   if (anOperation) {
     ModuleBase_IPropertyPanel* aPanel = anOperation->propertyPanel();
-    ModuleBase_ModelWidget* anActiveWidget = aPanel->activeWidget();
-    if (!anActiveWidget)
-      anActiveWidget = aPanel->preselectionWidget();
+    ModuleBase_ModelWidget* aCurrentWidget = aPanel->preselectionWidget();
+    if (!aCurrentWidget)
+      aCurrentWidget = myWorkshop->module()->activeWidget();
     ModuleBase_WidgetValidated* aWidgetValidated = dynamic_cast<ModuleBase_WidgetValidated*>
-                                                                           (anActiveWidget);
+                                                                           (aCurrentWidget);
     ModuleBase_ViewerPrs aPrs;
     myWorkshop->selection()->fillPresentation(aPrs, theOwner);