From aee1593678e52216b311881bef6b7f5e35759140 Mon Sep 17 00:00:00 2001 From: jean-pierre charras Date: Sun, 2 May 2021 16:02:33 +0200 Subject: [PATCH] Fix wxWidgets alerts Fixes #8346 https://gitlab.com/kicad/code/kicad/issues/8346 --- common/plotters/DXF_plotter.cpp | 2 +- eeschema/dialogs/dialog_plot_schematic_base.cpp | 2 +- eeschema/dialogs/dialog_plot_schematic_base.fbp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/common/plotters/DXF_plotter.cpp b/common/plotters/DXF_plotter.cpp index c590abfdbc..a0c5a76b3a 100644 --- a/common/plotters/DXF_plotter.cpp +++ b/common/plotters/DXF_plotter.cpp @@ -356,7 +356,7 @@ bool DXF_PLOTTER::StartPlot() - Greys (251 - 255) */ - wxASSERT( numLayers < NBCOLORS ); + wxASSERT( numLayers <= NBCOLORS ); for( EDA_COLOR_T i = BLACK; i < numLayers; i = static_cast( int( i ) + 1 ) ) { diff --git a/eeschema/dialogs/dialog_plot_schematic_base.cpp b/eeschema/dialogs/dialog_plot_schematic_base.cpp index abe505f319..4fe950b2f6 100644 --- a/eeschema/dialogs/dialog_plot_schematic_base.cpp +++ b/eeschema/dialogs/dialog_plot_schematic_base.cpp @@ -31,7 +31,7 @@ DIALOG_PLOT_SCHEMATIC_BASE::DIALOG_PLOT_SCHEMATIC_BASE( wxWindow* parent, wxWind bSizerDir->Add( m_outputDirectoryName, 1, wxALIGN_CENTER_VERTICAL|wxLEFT|wxRIGHT, 4 ); m_browseButton = new wxBitmapButton( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW|0 ); - bSizerDir->Add( m_browseButton, 0, wxALIGN_CENTER_HORIZONTAL|wxRIGHT, 5 ); + bSizerDir->Add( m_browseButton, 0, wxRIGHT|wxALIGN_CENTER_VERTICAL, 5 ); bMainSizer->Add( bSizerDir, 0, wxALL|wxEXPAND, 7 ); diff --git a/eeschema/dialogs/dialog_plot_schematic_base.fbp b/eeschema/dialogs/dialog_plot_schematic_base.fbp index 5d97b33c47..62d87c73f9 100644 --- a/eeschema/dialogs/dialog_plot_schematic_base.fbp +++ b/eeschema/dialogs/dialog_plot_schematic_base.fbp @@ -196,7 +196,7 @@ 5 - wxALIGN_CENTER_HORIZONTAL|wxRIGHT + wxRIGHT|wxALIGN_CENTER_VERTICAL 0 1