Fix logic in selecting power symbols for net highlighting

Fixes https://gitlab.com/kicad/code/kicad/-/issues/7339
This commit is contained in:
Jon Evans 2021-01-30 10:28:15 -05:00
parent 619e128536
commit 1d12f3fe4a
1 changed files with 2 additions and 2 deletions

View File

@ -830,8 +830,8 @@ static bool highlightNet( TOOL_MANAGER* aToolMgr, const VECTOR2D& aPosition )
}
else
{
SCH_ITEM* item = static_cast<SCH_ITEM*>( selTool->GetNode( aPosition ) );
SCH_COMPONENT* symbol = nullptr;
SCH_ITEM* item = static_cast<SCH_ITEM*>( selTool->GetNode( aPosition ) );
SCH_COMPONENT* symbol = dynamic_cast<SCH_COMPONENT*>( item );
if( item )
{