Fix bug with PCBNEW_PICKER_TOOL not doing a push/pop.

PICKER_TOOL got updated but PCBNEW_PICKER_TOOL didn't.
This commit is contained in:
Jeff Young 2019-07-16 20:20:57 +01:00
parent 8d79661996
commit ba7ad7ddf4
1 changed files with 3 additions and 0 deletions

View File

@ -44,6 +44,8 @@ int PCBNEW_PICKER_TOOL::Main( const TOOL_EVENT& aEvent )
GRID_HELPER grid( frame() ); GRID_HELPER grid( frame() );
int finalize_state = WAIT_CANCEL; int finalize_state = WAIT_CANCEL;
std::string tool = *aEvent.Parameter<std::string*>();
frame()->PushTool( tool );
Activate(); Activate();
setControls(); setControls();
@ -148,6 +150,7 @@ int PCBNEW_PICKER_TOOL::Main( const TOOL_EVENT& aEvent )
reset(); reset();
controls->ForceCursorPosition( false ); controls->ForceCursorPosition( false );
frame()->PopTool( tool );
return 0; return 0;
} }