From eece2de2e7f563906255b8069d7c00450a8b81de Mon Sep 17 00:00:00 2001 From: nds Date: Thu, 15 Feb 2018 10:15:41 +0300 Subject: [PATCH] Issue #2155 Trim removes multi-rotation constraint, undo leads to wrong DOF --- src/PartSet/PartSet_WidgetFeaturePointSelector.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/PartSet/PartSet_WidgetFeaturePointSelector.cpp b/src/PartSet/PartSet_WidgetFeaturePointSelector.cpp index 1b4be74c0..486138917 100644 --- a/src/PartSet/PartSet_WidgetFeaturePointSelector.cpp +++ b/src/PartSet/PartSet_WidgetFeaturePointSelector.cpp @@ -175,9 +175,12 @@ void PartSet_WidgetFeaturePointSelector::mouseReleased(ModuleBase_IViewWindow* t updateObject(feature()); - emit focusOutWidget(this); // we need to deselect base feature for better visibility of selected feature XGUI_Tools::workshop(myWorkshop)->displayer()->clearSelected(false); + + // focusOutWidget should be the last functionality in the method because after this emit, + // the widget may be deleted and members of this class are deleted (e.g. myWorkshop) + emit focusOutWidget(this); } //******************************************************************** -- 2.39.2