From 97fffe875fd9355505a20200bf24f038bf11df51 Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Sat, 24 Mar 2018 13:11:02 +0000 Subject: [PATCH] Notify clients when GRID_TRICKS toggles checkboxes. --- common/grid_tricks.cpp | 5 +++++ pcbnew/footprint_wizard_frame_functions.cpp | 4 ---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/common/grid_tricks.cpp b/common/grid_tricks.cpp index 69a1cd4826..6ffc29aac7 100644 --- a/common/grid_tricks.cpp +++ b/common/grid_tricks.cpp @@ -92,6 +92,11 @@ bool GRID_TRICKS::toggleCell( int aRow, int aCol ) // Mac needs this for the keyboard events; Linux appears to always need it. m_grid->ForceRefresh(); + // Let any clients know + wxGridEvent event( m_grid->GetId(), wxEVT_GRID_CELL_CHANGED, m_grid, aRow, aCol ); + event.SetString( model->GetValue( aRow, aCol ) ); + m_grid->GetEventHandler()->ProcessEvent( event ); + return true; } diff --git a/pcbnew/footprint_wizard_frame_functions.cpp b/pcbnew/footprint_wizard_frame_functions.cpp index 4b4cae2eea..39e9fa88ff 100644 --- a/pcbnew/footprint_wizard_frame_functions.cpp +++ b/pcbnew/footprint_wizard_frame_functions.cpp @@ -262,10 +262,6 @@ void FOOTPRINT_WIZARD_FRAME::ParametersUpdated( wxGridEvent& event ) bool has_changed = false; int count = m_parameterGrid->GetNumberRows(); - // Skip extra event, useless - if( event.GetString() == m_parameterGrid->GetCellValue( event.GetRow(), WIZ_COL_VALUE ) ) - return; - for( int prm_id = 0; prm_id < count; ++prm_id ) { wxString value = m_parameterGrid->GetCellValue( prm_id, WIZ_COL_VALUE );