From 294813d123259625eac77f1f611eda3eb7479f17 Mon Sep 17 00:00:00 2001 From: nds Date: Mon, 9 Nov 2015 13:39:57 +0300 Subject: [PATCH] A regression: when double clicking on a dimension for editing the value, the pop-up input does not exist anymore. --- src/ModuleBase/ModuleBase_WidgetEditor.h | 1 - src/PartSet/PartSet_SketcherMgr.cpp | 5 ++++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/ModuleBase/ModuleBase_WidgetEditor.h b/src/ModuleBase/ModuleBase_WidgetEditor.h index f63ec0bca..5f26a60cc 100644 --- a/src/ModuleBase/ModuleBase_WidgetEditor.h +++ b/src/ModuleBase/ModuleBase_WidgetEditor.h @@ -43,7 +43,6 @@ Q_OBJECT /// \return the state whether the widget can accept the focus virtual bool focusTo(); - private slots: /// Shous popup window under cursor for data editing void showPopupEditor(); diff --git a/src/PartSet/PartSet_SketcherMgr.cpp b/src/PartSet/PartSet_SketcherMgr.cpp index 601ca3337..ac3eaf7f9 100755 --- a/src/PartSet/PartSet_SketcherMgr.cpp +++ b/src/PartSet/PartSet_SketcherMgr.cpp @@ -11,6 +11,7 @@ #include "PartSet_WidgetPoint2dDistance.h" #include "PartSet_Tools.h" #include "PartSet_WidgetSketchLabel.h" +#include "PartSet_WidgetEditor.h" #include #include @@ -579,7 +580,9 @@ void PartSet_SketcherMgr::onMouseDoubleClick(ModuleBase_IViewWindow* theWnd, QMo // Find corresponded widget to activate value editing foreach (ModuleBase_ModelWidget* aWgt, aWidgets) { if (aWgt->attributeID() == "ConstraintValue") { - aWgt->focusTo(); + PartSet_WidgetEditor* anEditor = dynamic_cast(aWgt); + if (anEditor) + anEditor->showPopupEditor(); return; } } -- 2.39.2