Finish single-click-place drawing tool on double-click.
Fixes https://gitlab.com/kicad/code/kicad/issues/5907
This commit is contained in:
parent
75185f6723
commit
809f4c2ffb
|
@ -504,7 +504,7 @@ int SCH_DRAWING_TOOLS::SingleClickPlace( const TOOL_EVENT& aEvent )
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if( evt->IsClick( BUT_LEFT ) )
|
else if( evt->IsClick( BUT_LEFT ) || evt->IsDblClick( BUT_LEFT ) )
|
||||||
{
|
{
|
||||||
if( !m_frame->GetScreen()->GetItem( cursorPos, 0, type ) )
|
if( !m_frame->GetScreen()->GetItem( cursorPos, 0, type ) )
|
||||||
{
|
{
|
||||||
|
@ -523,6 +523,12 @@ int SCH_DRAWING_TOOLS::SingleClickPlace( const TOOL_EVENT& aEvent )
|
||||||
m_frame->OnModify();
|
m_frame->OnModify();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if( evt->IsDblClick( BUT_LEFT ) ) // Finish tool.
|
||||||
|
{
|
||||||
|
m_frame->PopTool( tool );
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if( evt->IsClick( BUT_RIGHT ) )
|
else if( evt->IsClick( BUT_RIGHT ) )
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue