From 1d8fd22cd8714f1ee32db685134e5ee2c80a2805 Mon Sep 17 00:00:00 2001 From: Wayne Stambaugh Date: Fri, 20 Aug 2021 15:45:57 -0400 Subject: [PATCH] Symbol editor: fix message panel units when selecting from combo box. Fixes https://gitlab.com/kicad/code/kicad/-/issues/8991 --- eeschema/symbol_editor/symbol_edit_frame.cpp | 5 +++-- eeschema/symbol_editor/symbol_edit_frame.h | 4 ++-- eeschema/symbol_editor/symbol_editor.cpp | 6 +++--- eeschema/tools/symbol_editor_edit_tool.cpp | 2 +- 4 files changed, 9 insertions(+), 8 deletions(-) diff --git a/eeschema/symbol_editor/symbol_edit_frame.cpp b/eeschema/symbol_editor/symbol_edit_frame.cpp index 9bbf6ca70a..083f8a6207 100644 --- a/eeschema/symbol_editor/symbol_edit_frame.cpp +++ b/eeschema/symbol_editor/symbol_edit_frame.cpp @@ -158,7 +158,7 @@ SYMBOL_EDIT_FRAME::SYMBOL_EDIT_FRAME( KIWAY* aKiway, wxWindow* aParent ) : ReCreateOptToolbar(); updateTitle(); - DisplaySymbolDatasheet(); + UpdateSymbolMsgPanelInfo(); RebuildSymbolUnitsList(); m_auimgr.SetManagedWindow( this ); @@ -629,6 +629,7 @@ void SYMBOL_EDIT_FRAME::OnSelectUnit( wxCommandEvent& event ) m_toolManager->ResetTools( TOOL_BASE::MODEL_RELOAD ); RebuildView(); + UpdateSymbolMsgPanelInfo(); } @@ -1330,7 +1331,7 @@ void SYMBOL_EDIT_FRAME::LoadSymbolFromSchematic( SCH_SYMBOL* aSymbol ) updateTitle(); RebuildSymbolUnitsList(); SetShowDeMorgan( GetCurSymbol()->HasConversion() ); - DisplaySymbolDatasheet(); + UpdateSymbolMsgPanelInfo(); Refresh(); } diff --git a/eeschema/symbol_editor/symbol_edit_frame.h b/eeschema/symbol_editor/symbol_edit_frame.h index ee643b7dbb..a3a4b2519d 100644 --- a/eeschema/symbol_editor/symbol_edit_frame.h +++ b/eeschema/symbol_editor/symbol_edit_frame.h @@ -229,7 +229,7 @@ public: void ClearMsgPanel() override { - DisplaySymbolDatasheet(); + UpdateSymbolMsgPanelInfo(); } bool IsSymbolFromSchematic() const { return m_isSymbolFromSchematic; } @@ -239,7 +239,7 @@ public: /** * Display the documentation of the selected symbol. */ - void DisplaySymbolDatasheet(); + void UpdateSymbolMsgPanelInfo(); // General editing /** diff --git a/eeschema/symbol_editor/symbol_editor.cpp b/eeschema/symbol_editor/symbol_editor.cpp index c4e06e877b..778776e81b 100644 --- a/eeschema/symbol_editor/symbol_editor.cpp +++ b/eeschema/symbol_editor/symbol_editor.cpp @@ -365,7 +365,7 @@ bool SYMBOL_EDIT_FRAME::LoadOneLibrarySymbolAux( LIB_SYMBOL* aEntry, const wxStr // Display the document information based on the entry selected just in // case the entry is an alias. - DisplaySymbolDatasheet(); + UpdateMsgPanel(); Refresh(); return true; @@ -727,7 +727,7 @@ void SYMBOL_EDIT_FRAME::UpdateAfterSymbolProperties( wxString* aOldName ) RebuildSymbolUnitsList(); SetShowDeMorgan( GetCurSymbol()->Flatten()->HasConversion() ); updateTitle(); - DisplaySymbolDatasheet(); + UpdateMsgPanel(); RebuildView(); OnModify(); @@ -1184,7 +1184,7 @@ bool SYMBOL_EDIT_FRAME::saveAllLibraries( bool aRequireConfirmation ) } -void SYMBOL_EDIT_FRAME::DisplaySymbolDatasheet() +void SYMBOL_EDIT_FRAME::UpdateSymbolMsgPanelInfo() { EDA_DRAW_FRAME::ClearMsgPanel(); diff --git a/eeschema/tools/symbol_editor_edit_tool.cpp b/eeschema/tools/symbol_editor_edit_tool.cpp index 5470b6145b..1566837393 100644 --- a/eeschema/tools/symbol_editor_edit_tool.cpp +++ b/eeschema/tools/symbol_editor_edit_tool.cpp @@ -549,7 +549,7 @@ void SYMBOL_EDITOR_EDIT_TOOL::editFieldProperties( LIB_FIELD* aField ) updateItem( aField, true ); m_frame->GetCanvas()->Refresh(); m_frame->OnModify(); - m_frame->DisplaySymbolDatasheet(); + m_frame->UpdateSymbolMsgPanelInfo(); } }