Clear view before deleting part.

Fixes https://gitlab.com/kicad/code/kicad/issues/6658
This commit is contained in:
Jeff Young 2020-12-07 15:49:39 +00:00
parent 78129aabeb
commit 893f1bb4c1
1 changed files with 2 additions and 1 deletions

View File

@ -672,8 +672,9 @@ wxString SYMBOL_EDIT_FRAME::SetCurLib( const wxString& aLibNickname )
void SYMBOL_EDIT_FRAME::SetCurPart( LIB_PART* aPart )
{
m_toolManager->RunAction( EE_ACTIONS::clearSelection, true );
GetCanvas()->GetView()->Clear();
delete m_my_part;
m_my_part = aPart;
// select the current component in the tree widget