Remove UpdatePins call from connectivity calculation

This commit is contained in:
Jon Evans 2019-04-22 22:49:24 -04:00
parent 098102220e
commit 0ce32f7be1
1 changed files with 4 additions and 1 deletions

View File

@ -439,10 +439,13 @@ void CONNECTION_GRAPH::updateItemConnectivity( SCH_SHEET_PATH aSheet,
SCH_COMPONENT* component = static_cast<SCH_COMPONENT*>( item ); SCH_COMPONENT* component = static_cast<SCH_COMPONENT*>( item );
TRANSFORM t = component->GetTransform(); TRANSFORM t = component->GetTransform();
component->UpdatePins( &aSheet ); // Assumption: we don't need to call UpdatePins() here because anything
// that would change the pins of the component will have called it already
for( SCH_PIN& pin : component->GetPins() ) for( SCH_PIN& pin : component->GetPins() )
{ {
pin.InitializeConnection( aSheet );
wxPoint pos = t.TransformCoordinate( pin.GetPosition() ) + component->GetPosition(); wxPoint pos = t.TransformCoordinate( pin.GetPosition() ) + component->GetPosition();
// because calling the first time is not thread-safe // because calling the first time is not thread-safe