Better handle many (MANY) duplicate refs
In large designs with thousands of duplicate elements (e.g. power
symbols), we need to be smart about vector management. Removing all but
the first few items should be batched and not element at a time
Ref: KSC-885
(cherry picked from commit b43f037a91
)
This commit is contained in:
parent
4b0416e92a
commit
76a3b3db97
|
@ -652,8 +652,7 @@ void SCH_REFERENCE_LIST::Annotate( bool aUseSheetNum, int aSheetIntervalId, int
|
|||
}
|
||||
|
||||
// Remove aAdditionalRefs references
|
||||
for( size_t i = originalSize; i < ( aAdditionalRefs.GetCount() + originalSize ); i++ )
|
||||
RemoveItem( originalSize );
|
||||
m_flatList.erase( m_flatList.begin() + originalSize, m_flatList.end() );
|
||||
|
||||
wxASSERT( originalSize == GetCount() ); // Make sure we didn't make a mistake
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue