Ensure symbols in subsheets are added to multi-unit map before re-annotating

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14918

(cherry picked from commit 6d3f512e15)
This commit is contained in:
Roberto Fernandez Bautista 2023-06-28 23:29:43 +02:00
parent ed1eb1c018
commit 74b1f603df
1 changed files with 7 additions and 0 deletions

View File

@ -276,12 +276,19 @@ void SCH_EDIT_FRAME::AnnotateSymbols( ANNOTATE_SCOPE_T aAnnotateScope,
case ANNOTATE_CURRENT_SHEET:
currentSheet.GetMultiUnitSymbols( lockedSymbols );
if( aRecursive )
subSheets.GetMultiUnitSymbols( lockedSymbols );
break;
case ANNOTATE_SELECTION:
for( SCH_SYMBOL* symbol : selectedSymbols )
currentSheet.AppendMultiUnitSymbol( lockedSymbols, symbol );
if( aRecursive )
selectedSheets.GetMultiUnitSymbols( lockedSymbols );
break;
}