From 3bddadc03d17d26bf7676d586b9904e4a56b68ec Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Sun, 22 Aug 2021 19:54:42 +0100 Subject: [PATCH] Fix a typo in reference clearing. Also fixes an unrelated bug where all values/footprints were getting reset rather than just the instance versions. Fixes https://gitlab.com/kicad/code/kicad/issues/8891 --- eeschema/sch_symbol.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/eeschema/sch_symbol.cpp b/eeschema/sch_symbol.cpp index 6a11124c69..3293b0b46f 100644 --- a/eeschema/sch_symbol.cpp +++ b/eeschema/sch_symbol.cpp @@ -784,7 +784,7 @@ void SCH_SYMBOL::UpdateFields( const SCH_SHEET_PATH* aPath, bool aUpdateStyle, b if( id == REFERENCE_FIELD && aPath ) { - if( aResetOtherFields ) + if( aResetRef ) SetRef( aPath, m_part->GetReferenceField().GetText() ); else if( aUpdateRef ) SetRef( aPath, libField->GetText() ); @@ -792,14 +792,14 @@ void SCH_SYMBOL::UpdateFields( const SCH_SHEET_PATH* aPath, bool aUpdateStyle, b else if( id == VALUE_FIELD ) { if( aResetOtherFields ) - SetValue( UnescapeString( m_lib_id.GetLibItemName() ) ); // alias-specific value + SetValue( aPath, UnescapeString( m_lib_id.GetLibItemName() ) ); // alias-specific value else - SetValue( UnescapeString( libField->GetText() ) ); + SetValue( aPath, UnescapeString( libField->GetText() ) ); } else if( id == FOOTPRINT_FIELD ) { if( aResetOtherFields || aUpdateOtherFields ) - SetFootprint( libField->GetText() ); + SetFootprint( aPath, libField->GetText() ); } else if( id == DATASHEET_FIELD ) {