From 3bcb728c84a1dc4200bf548040ab338562e87944 Mon Sep 17 00:00:00 2001 From: Maciej Suminski Date: Tue, 13 May 2014 11:22:51 +0200 Subject: [PATCH] Fixed modification point for EDIT_TOOL when the tool is not active. --- pcbnew/tools/edit_tool.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pcbnew/tools/edit_tool.cpp b/pcbnew/tools/edit_tool.cpp index b647b2bbf2..c0e30627dc 100644 --- a/pcbnew/tools/edit_tool.cpp +++ b/pcbnew/tools/edit_tool.cpp @@ -492,6 +492,11 @@ wxPoint EDIT_TOOL::getModificationPoint( const SELECTION_TOOL::SELECTION& aSelec } else { + // If EDIT_TOOL is not currently active then it means that the cursor position is not + // updated, so we have to fetch the latest value + if( m_toolMgr->GetCurrentToolId() != m_toolId ) + m_cursor = getViewControls()->GetCursorPosition(); + return wxPoint( m_cursor.x, m_cursor.y ); } }