From ddb9de3ecfcf4e0129978a673424ec6f384e7d36 Mon Sep 17 00:00:00 2001 From: John Beard Date: Sat, 12 Oct 2024 00:55:59 +0800 Subject: [PATCH] Design block: fix uninitialised variables on load Thse were just omitted from the JSON loader, so they were uninitialised. Valgrind doesn't like them because they get compared to things before being set. --- eeschema/eeschema_settings.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/eeschema/eeschema_settings.cpp b/eeschema/eeschema_settings.cpp index 330af3d2d8..4b54296cad 100644 --- a/eeschema/eeschema_settings.cpp +++ b/eeschema/eeschema_settings.cpp @@ -650,6 +650,9 @@ EESCHEMA_SETTINGS::EESCHEMA_SETTINGS() : m_params.emplace_back( new PARAM( "symbol_chooser.place_all_units", &m_SymChooserPanel.place_all_units, true ) ); + m_params.emplace_back( new PARAM( "design_block_chooser.sash_pos_h", + &m_DesignBlockChooserPanel.sash_pos_h, -1 ) ); + m_params.emplace_back( new PARAM( "design_block_chooser.sash_pos_v", &m_DesignBlockChooserPanel.sash_pos_v, -1 ) ); @@ -668,6 +671,9 @@ EESCHEMA_SETTINGS::EESCHEMA_SETTINGS() : m_params.emplace_back( new PARAM( "design_block_chooser.place_as_sheet", &m_DesignBlockChooserPanel.place_as_sheet, false ) ); + m_params.emplace_back( new PARAM( "design_block_chooser.keep_annotations", + &m_DesignBlockChooserPanel.keep_annotations, false ) ); + m_params.emplace_back( new PARAM( "import_graphics.interactive_placement", &m_ImportGraphics.interactive_placement, true ) );