Fixed switching back to selection tool using the right toolbar buttons in pcbnew (GAL).

This commit is contained in:
Maciej Suminski 2014-04-07 13:50:18 +02:00
parent 6fa2f060fa
commit 7dc08c8718
1 changed files with 3 additions and 2 deletions

View File

@ -1374,7 +1374,7 @@ void PCB_EDIT_FRAME::OnSelectTool( wxCommandEvent& aEvent )
{ {
std::string actionName = COMMON_ACTIONS::TranslateLegacyId( id ); std::string actionName = COMMON_ACTIONS::TranslateLegacyId( id );
if( !actionName.empty() ) if( !actionName.empty() || id == ID_NO_TOOL_SELECTED )
{ {
const int MAX_TRIALS = 10; const int MAX_TRIALS = 10;
int trials = 0; int trials = 0;
@ -1389,6 +1389,7 @@ void PCB_EDIT_FRAME::OnSelectTool( wxCommandEvent& aEvent )
m_toolManager.ProcessEvent( cancel ); m_toolManager.ProcessEvent( cancel );
} }
if( !actionName.empty() )
m_toolManager.RunAction( actionName ); m_toolManager.RunAction( actionName );
} }
} }