Reset m_inDrawingTool on exit.

Fixes https://gitlab.com/kicad/code/kicad/issues/8653
This commit is contained in:
Jeff Young 2021-06-22 12:52:40 +01:00
parent a495a57602
commit 7efca0113d
1 changed files with 5 additions and 1 deletions

View File

@ -1143,12 +1143,16 @@ int DRAWING_TOOL::PlaceImportedGraphics( const TOOL_EVENT& aEvent )
std::list<std::unique_ptr<EDA_ITEM>>& list = dlg.GetImportedItems();
if( dlgResult != wxID_OK )
{
m_inDrawingTool = false;
return 0;
}
// Ensure the list is not empty:
if( list.empty() )
{
wxMessageBox( _( "No graphic items found in file to import") );
wxMessageBox( _( "No graphic items found in file.") );
m_inDrawingTool = false;
return 0;
}