diff --git a/eeschema/dialogs/panel_sym_lib_table.cpp b/eeschema/dialogs/panel_sym_lib_table.cpp index a85ae91db8..4a18537a1c 100644 --- a/eeschema/dialogs/panel_sym_lib_table.cpp +++ b/eeschema/dialogs/panel_sym_lib_table.cpp @@ -559,8 +559,8 @@ void PANEL_SYM_LIB_TABLE::browseLibrariesHandler( wxCommandEvent& event ) if( !filePathsList.IsEmpty() ) { - m_cur_grid->MakeCellVisible( m_cur_grid->GetNumberRows() - 1, 0 ); - m_cur_grid->SetGridCursor( m_cur_grid->GetNumberRows() - 1, 1 ); + m_cur_grid->MakeCellVisible( m_cur_grid->GetNumberRows() - 1, COL_ENABLED ); + m_cur_grid->SetGridCursor( m_cur_grid->GetNumberRows() - 1, COL_NICKNAME ); } } @@ -575,8 +575,8 @@ void PANEL_SYM_LIB_TABLE::appendRowHandler( wxCommandEvent& event ) int row = m_cur_grid->GetNumberRows() - 1; // wx documentation is wrong, SetGridCursor does not make visible. - m_cur_grid->MakeCellVisible( row, 0 ); - m_cur_grid->SetGridCursor( row, 1 ); + m_cur_grid->MakeCellVisible( row, COL_ENABLED ); + m_cur_grid->SetGridCursor( row, COL_NICKNAME ); m_cur_grid->EnableCellEditControl( true ); m_cur_grid->ShowCellEditControl(); } diff --git a/pcbnew/dialogs/panel_fp_lib_table.cpp b/pcbnew/dialogs/panel_fp_lib_table.cpp index c1f125f859..7a356606fd 100644 --- a/pcbnew/dialogs/panel_fp_lib_table.cpp +++ b/pcbnew/dialogs/panel_fp_lib_table.cpp @@ -655,8 +655,8 @@ void PANEL_FP_LIB_TABLE::appendRowHandler( wxCommandEvent& event ) int last_row = m_cur_grid->GetNumberRows() - 1; // wx documentation is wrong, SetGridCursor does not make visible. - m_cur_grid->MakeCellVisible( last_row, 0 ); - m_cur_grid->SetGridCursor( last_row, 1 ); + m_cur_grid->MakeCellVisible( last_row, COL_ENABLED ); + m_cur_grid->SetGridCursor( last_row, COL_NICKNAME ); m_cur_grid->EnableCellEditControl( true ); m_cur_grid->ShowCellEditControl(); }