Fix optimization to not fetch all possible endpoints for non-connectable.
This commit is contained in:
parent
fad385785d
commit
7901d705ba
|
@ -590,6 +590,8 @@ void SCH_LINE::GetEndPoints( std::vector <DANGLING_END_ITEM>& aItemList )
|
||||||
bool SCH_LINE::UpdateDanglingState( std::vector<DANGLING_END_ITEM>& aItemList,
|
bool SCH_LINE::UpdateDanglingState( std::vector<DANGLING_END_ITEM>& aItemList,
|
||||||
const SCH_SHEET_PATH* aPath )
|
const SCH_SHEET_PATH* aPath )
|
||||||
{
|
{
|
||||||
|
if( IsConnectable() )
|
||||||
|
{
|
||||||
bool previousStartState = m_startIsDangling;
|
bool previousStartState = m_startIsDangling;
|
||||||
bool previousEndState = m_endIsDangling;
|
bool previousEndState = m_endIsDangling;
|
||||||
|
|
||||||
|
@ -618,8 +620,11 @@ bool SCH_LINE::UpdateDanglingState( std::vector<DANGLING_END_ITEM>& aItemList,
|
||||||
// has changed or not (and returning true will result in extra work)
|
// has changed or not (and returning true will result in extra work)
|
||||||
if( IsBus() )
|
if( IsBus() )
|
||||||
return false;
|
return false;
|
||||||
else
|
|
||||||
return previousStartState != m_startIsDangling || previousEndState != m_endIsDangling;
|
return previousStartState != m_startIsDangling || previousEndState != m_endIsDangling;
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -981,6 +981,8 @@ void SCH_SCREEN::TestDanglingEnds( const SCH_SHEET_PATH* aPath,
|
||||||
std::vector<DANGLING_END_ITEM> endPoints;
|
std::vector<DANGLING_END_ITEM> endPoints;
|
||||||
|
|
||||||
for( SCH_ITEM* item : Items() )
|
for( SCH_ITEM* item : Items() )
|
||||||
|
{
|
||||||
|
if( item->IsConnectable() )
|
||||||
{
|
{
|
||||||
endPoints.clear();
|
endPoints.clear();
|
||||||
|
|
||||||
|
@ -993,6 +995,7 @@ void SCH_SCREEN::TestDanglingEnds( const SCH_SHEET_PATH* aPath,
|
||||||
(*aChangedHandler)( item );
|
(*aChangedHandler)( item );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue