eeschema/intersheet: don't list own page

This commit is contained in:
Franck Jullien 2020-11-23 11:16:47 +01:00 committed by Seth Hillbrand
parent dad2e317e9
commit 70cbf59846
1 changed files with 5 additions and 0 deletions

View File

@ -1127,6 +1127,11 @@ bool SCH_GLOBALLABEL::ResolveTextVar( wxString* token, int aDepth ) const
pageListCopy.insert( pageListCopy.end(), it->second.begin(), it->second.end() );
std::sort( pageListCopy.begin(), pageListCopy.end() );
wxString currentPage = Schematic()->CurrentSheet().GetPageNumber();
pageListCopy.erase( std::remove( pageListCopy.begin(),
pageListCopy.end(),
currentPage ), pageListCopy.end() );
token->Printf( "%s", settings.m_IntersheetRefsPrefix );
if( ( settings.m_IntersheetRefsFormatShort ) && ( pageListCopy.size() > 2 ) )