Reset tools before switching footprints.

Fixes: lp:1776777
* https://bugs.launchpad.net/kicad/+bug/1776777
This commit is contained in:
Jeff Young 2018-06-14 09:54:49 +01:00
parent 0d4d24ed22
commit b37969f584
1 changed files with 3 additions and 3 deletions

View File

@ -466,9 +466,9 @@ void FOOTPRINT_VIEWER_FRAME::ClickOnFootprintList( wxCommandEvent& event )
{
setCurFootprintName( name );
SetCurItem( NULL );
// Delete the current footprint
// Delete the current footprint (MUST reset tools first)
GetToolManager()->ResetTools( TOOL_BASE::MODEL_RELOAD );
SetCurItem( nullptr );
GetBoard()->m_Modules.DeleteAll();
LIB_ID id;