From 449488ca8b3f6732a3be6f0a3721326adb41075c Mon Sep 17 00:00:00 2001 From: ouv Date: Tue, 9 Jul 2013 08:40:20 +0000 Subject: [PATCH] Sketching. --- src/GraphicsView/GraphicsView_ViewPort.cxx | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/GraphicsView/GraphicsView_ViewPort.cxx b/src/GraphicsView/GraphicsView_ViewPort.cxx index 9b2aa85ac..3ce7a5199 100644 --- a/src/GraphicsView/GraphicsView_ViewPort.cxx +++ b/src/GraphicsView/GraphicsView_ViewPort.cxx @@ -1401,7 +1401,7 @@ void GraphicsView_ViewPort::drawSketching( const QPointF& thePoint ) //================================================================ void GraphicsView_ViewPort::finishSketching( bool theStatus ) { - prepareToSketch( false ); // just in case + prepareToSketch( false ); mySketchingItem->setVisible( false ); myIsSketching = false; @@ -1594,6 +1594,12 @@ bool GraphicsView_ViewPort::cancelCurrentOperation() return true; } + if( isSketching() || isPrepareToSketch() ) + { + finishSketching( false ); + return true; + } + return false; } -- 2.39.2