From 4b3772cf07e13fd6ea79292c05d03c85f89b8958 Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Wed, 25 Apr 2018 00:35:37 +0100 Subject: [PATCH] Update value field when changing power symbol reference. Fixes: lp:1765932 * https://bugs.launchpad.net/kicad/+bug/1765932 --- .../dialogs/dialog_edit_component_in_schematic.cpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/eeschema/dialogs/dialog_edit_component_in_schematic.cpp b/eeschema/dialogs/dialog_edit_component_in_schematic.cpp index 12f69c269c..0126f61f11 100644 --- a/eeschema/dialogs/dialog_edit_component_in_schematic.cpp +++ b/eeschema/dialogs/dialog_edit_component_in_schematic.cpp @@ -300,6 +300,19 @@ void DIALOG_EDIT_COMPONENT_IN_SCHEMATIC::OnSelectChipName( wxCommandEvent& event return; chipnameTextCtrl->SetValue( sel.LibId.Format() ); + + // Update the value field for Power symbols + LIB_PART* entry = GetParent()->GetLibPart( sel.LibId ); + + if( entry && entry->IsPower() ) + { + m_FieldsBuf[VALUE].SetText( sel.LibId.GetLibItemName() ); + setRowItem( VALUE, m_FieldsBuf[VALUE] ); + + if( s_SelectedRow == VALUE ) + copySelectedFieldToPanel(); + } + }