From 5488595c4524089e729eabd422c65185b4b0ad14 Mon Sep 17 00:00:00 2001 From: mkr Date: Wed, 25 Nov 2015 18:43:47 +0300 Subject: [PATCH] refs #736: fix displaying of ghost of polyline section in addition mode. --- src/CurveCreator/CurveCreator_Widget.cxx | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/CurveCreator/CurveCreator_Widget.cxx b/src/CurveCreator/CurveCreator_Widget.cxx index 54cf166bb..0bbccc6a1 100644 --- a/src/CurveCreator/CurveCreator_Widget.cxx +++ b/src/CurveCreator/CurveCreator_Widget.cxx @@ -1005,10 +1005,18 @@ void CurveCreator_Widget::onMousePress( SUIT_ViewWindow*, QMouseEvent* theEvent */ void CurveCreator_Widget::onMouseRelease( SUIT_ViewWindow* theWindow, QMouseEvent* theEvent ) { - if ( getActionMode() != ModificationMode ) + ActionMode aMode = getActionMode(); + if ( aMode != ModificationMode ) { // Emit selectionChanged() signal getOCCViewer()->performSelectionChanged(); + + if ( aMode == AdditionMode ) + { + Handle(AIS_InteractiveContext) aCtx = getAISContext(); + if ( !aCtx.IsNull() ) + aCtx->ClearSelected(); + } return; } if (theEvent->button() != Qt::LeftButton) return; -- 2.39.2