fp editor: fix crash (null pointer) when trying to drag an item.
(there is no roter tool in fp editor) Fixes #9476 https://gitlab.com/kicad/code/kicad/issues/9476
This commit is contained in:
parent
4a9b3d9673
commit
1dbe8442b1
|
@ -273,6 +273,9 @@ bool EDIT_TOOL::isRouterActive() const
|
||||||
|
|
||||||
int EDIT_TOOL::Drag( const TOOL_EVENT& aEvent )
|
int EDIT_TOOL::Drag( const TOOL_EVENT& aEvent )
|
||||||
{
|
{
|
||||||
|
if( !m_toolMgr->GetTool<ROUTER_TOOL>() )
|
||||||
|
return false; // don't drag when no router tool (i.e. fp editor)
|
||||||
|
|
||||||
if( m_toolMgr->GetTool<ROUTER_TOOL>()->IsToolActive() )
|
if( m_toolMgr->GetTool<ROUTER_TOOL>()->IsToolActive() )
|
||||||
return false; // don't drag when router is already active
|
return false; // don't drag when router is already active
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue