diff --git a/gerbview/DCodeSelectionbox.cpp b/gerbview/DCodeSelectionbox.cpp index 34e67d7552..7d9a422326 100644 --- a/gerbview/DCodeSelectionbox.cpp +++ b/gerbview/DCodeSelectionbox.cpp @@ -22,7 +22,6 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include #include #include #include diff --git a/gerbview/am_primitive.cpp b/gerbview/am_primitive.cpp index 77356dc25d..e8cdff3889 100644 --- a/gerbview/am_primitive.cpp +++ b/gerbview/am_primitive.cpp @@ -7,7 +7,7 @@ * * Copyright (C) 1992-2017 Jean-Pierre Charras * Copyright (C) 2010 SoftPLC Corporation, Dick Hollenbeck - * Copyright (C) 1992-2019 KiCad Developers, see AUTHORS.txt for contributors. + * Copyright (C) 1992-2020 KiCad Developers, see AUTHORS.txt for contributors. * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License @@ -27,18 +27,15 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include -#include #include #include #include -#include #include // for KiROUND #include #include +#include /** diff --git a/gerbview/clear_gbr_drawlayers.cpp b/gerbview/clear_gbr_drawlayers.cpp index 614a7b8cb0..7cf1cf63e9 100644 --- a/gerbview/clear_gbr_drawlayers.cpp +++ b/gerbview/clear_gbr_drawlayers.cpp @@ -27,7 +27,7 @@ * @brief erase a given or all draw layers, an free memory relative to the cleared layer(s) */ -#include +//#include #include #include #include diff --git a/gerbview/dcode.cpp b/gerbview/dcode.cpp index ec28e9bb12..2b55dfe5f9 100644 --- a/gerbview/dcode.cpp +++ b/gerbview/dcode.cpp @@ -28,8 +28,6 @@ * @brief D_CODE class implementation */ -#include -#include #include #include #include diff --git a/gerbview/dialogs/panel_gerbview_settings.cpp b/gerbview/dialogs/panel_gerbview_settings.cpp index 3061ec77a2..8e18e8cd23 100644 --- a/gerbview/dialogs/panel_gerbview_settings.cpp +++ b/gerbview/dialogs/panel_gerbview_settings.cpp @@ -19,14 +19,25 @@ */ -#include -#include #include #include #include "panel_gerbview_settings.h" +/// List of page sizes +static const wxChar* gerberPageSizeList[] = +{ + wxT( "GERBER" ), // index 0: full size page selection + wxT( "A4" ), + wxT( "A3" ), + wxT( "A2" ), + wxT( "A" ), + wxT( "B" ), + wxT( "C" ), +}; + + PANEL_GERBVIEW_SETTINGS::PANEL_GERBVIEW_SETTINGS( GERBVIEW_FRAME *aFrame, wxWindow* aWindow ) : PANEL_GERBVIEW_SETTINGS_BASE( aWindow, wxID_ANY ), m_Parent( aFrame ) @@ -40,9 +51,9 @@ bool PANEL_GERBVIEW_SETTINGS::TransferDataToWindow( ) m_BoxUnits->SetSelection( ( m_Parent->GetUserUnits() == EDA_UNITS::MILLIMETRES ) ? 1 : 0 ); m_ShowPageLimitsOpt->SetValue( m_Parent->GetDisplayOptions().m_DisplayPageLimits ); - for( unsigned i = 0; i < arrayDim( g_GerberPageSizeList ); ++i ) + for( unsigned i = 0; i < arrayDim( gerberPageSizeList ); ++i ) { - if( g_GerberPageSizeList[i] == m_Parent->GetPageSettings().GetType() ) + if( gerberPageSizeList[i] == m_Parent->GetPageSettings().GetType() ) { m_PageSize->SetSelection( i ); break; @@ -62,7 +73,7 @@ bool PANEL_GERBVIEW_SETTINGS::TransferDataFromWindow() auto opts = m_Parent->GetDisplayOptions(); opts.m_DisplayPageLimits = m_ShowPageLimitsOpt->GetValue(); - PAGE_INFO pageInfo( g_GerberPageSizeList[ m_PageSize->GetSelection() ] ); + PAGE_INFO pageInfo( gerberPageSizeList[ m_PageSize->GetSelection() ] ); m_Parent->SetPageSettings( pageInfo ); m_Parent->UpdateDisplayOptions( opts ); diff --git a/gerbview/events_called_functions.cpp b/gerbview/events_called_functions.cpp index df29526c50..c544267f7d 100644 --- a/gerbview/events_called_functions.cpp +++ b/gerbview/events_called_functions.cpp @@ -22,7 +22,6 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include #include #include #include diff --git a/gerbview/export_to_pcbnew.cpp b/gerbview/export_to_pcbnew.cpp index 45e5ded388..899c077373 100644 --- a/gerbview/export_to_pcbnew.cpp +++ b/gerbview/export_to_pcbnew.cpp @@ -29,8 +29,6 @@ #include -#include -#include #include #include #include diff --git a/gerbview/files.cpp b/gerbview/files.cpp index 0b008d94cc..b7572cee5a 100644 --- a/gerbview/files.cpp +++ b/gerbview/files.cpp @@ -22,10 +22,8 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include #include #include -#include #include #include #include diff --git a/gerbview/gbr_layer_box_selector.cpp b/gerbview/gbr_layer_box_selector.cpp index 827421a7b0..fb72b683be 100644 --- a/gerbview/gbr_layer_box_selector.cpp +++ b/gerbview/gbr_layer_box_selector.cpp @@ -29,7 +29,6 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include #include #include diff --git a/gerbview/gbr_layout.cpp b/gerbview/gbr_layout.cpp index d2ffff315f..32e2d2fe8d 100644 --- a/gerbview/gbr_layout.cpp +++ b/gerbview/gbr_layout.cpp @@ -22,9 +22,6 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include -#include #include #include #include diff --git a/gerbview/gbr_layout.h b/gerbview/gbr_layout.h index 19d3350ea7..489ce34561 100644 --- a/gerbview/gbr_layout.h +++ b/gerbview/gbr_layout.h @@ -32,7 +32,7 @@ #define GBR_LAYOUT_H -#include // PAGE_INFO +//#include // PAGE_INFO #include // GERBER_DRAWLAYERS_COUNT #include #include diff --git a/gerbview/gerber_draw_item.cpp b/gerbview/gerber_draw_item.cpp index aaa18da57b..cebc35d539 100644 --- a/gerbview/gerber_draw_item.cpp +++ b/gerbview/gerber_draw_item.cpp @@ -22,9 +22,6 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include -#include #include #include #include diff --git a/gerbview/gerber_file_image.cpp b/gerbview/gerber_file_image.cpp index 801c849fcf..f43f064eb3 100644 --- a/gerbview/gerber_file_image.cpp +++ b/gerbview/gerber_file_image.cpp @@ -27,9 +27,6 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include -#include #include #include #include diff --git a/gerbview/gerber_file_image_list.cpp b/gerbview/gerber_file_image_list.cpp index 2e71c667f3..5fc2b2cea7 100644 --- a/gerbview/gerber_file_image_list.cpp +++ b/gerbview/gerber_file_image_list.cpp @@ -27,8 +27,6 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include - #include #include #include diff --git a/gerbview/gerbview.cpp b/gerbview/gerbview.cpp index 3d37a30ed8..388bd4c728 100644 --- a/gerbview/gerbview.cpp +++ b/gerbview/gerbview.cpp @@ -26,7 +26,6 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include #include #include #include @@ -39,17 +38,6 @@ using json = nlohmann::json; -const wxChar* g_GerberPageSizeList[] = -{ - wxT( "GERBER" ), // index 0: full size page selection - wxT( "A4" ), - wxT( "A3" ), - wxT( "A2" ), - wxT( "A" ), - wxT( "B" ), - wxT( "C" ), -}; - namespace GERBV { diff --git a/gerbview/gerbview.h b/gerbview/gerbview.h index ed23005465..6038c034bb 100644 --- a/gerbview/gerbview.h +++ b/gerbview/gerbview.h @@ -29,13 +29,6 @@ #include -#define CURSEUR_ON_GRILLE 0 -#define CURSEUR_OFF_GRILLE 1 - -/// List of page sizes -extern const wxChar* g_GerberPageSizeList[7]; - - // Interpolation type enum Gerb_Interpolation { diff --git a/gerbview/gerbview_frame.cpp b/gerbview/gerbview_frame.cpp index 3c1c258ebb..d81468d443 100644 --- a/gerbview/gerbview_frame.cpp +++ b/gerbview/gerbview_frame.cpp @@ -18,11 +18,9 @@ * with this program. If not, see . */ -#include #include #include #include -#include #include #include #include diff --git a/gerbview/gerbview_layer_widget.cpp b/gerbview/gerbview_layer_widget.cpp index eff1b8319f..2d82a4151f 100644 --- a/gerbview/gerbview_layer_widget.cpp +++ b/gerbview/gerbview_layer_widget.cpp @@ -23,9 +23,6 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include -#include #include #include #include diff --git a/gerbview/gerbview_printout.cpp b/gerbview/gerbview_printout.cpp index 5af3e84a94..df854c5f2c 100644 --- a/gerbview/gerbview_printout.cpp +++ b/gerbview/gerbview_printout.cpp @@ -22,8 +22,6 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include #include #include #include diff --git a/gerbview/job_file_reader.cpp b/gerbview/job_file_reader.cpp index a7f441e6e5..f7a8a49cbf 100644 --- a/gerbview/job_file_reader.cpp +++ b/gerbview/job_file_reader.cpp @@ -26,7 +26,6 @@ * @file job_file_reader.cpp */ -#include #include #include diff --git a/gerbview/readgerb.cpp b/gerbview/readgerb.cpp index 9bf127f707..cf8eeaa3bd 100644 --- a/gerbview/readgerb.cpp +++ b/gerbview/readgerb.cpp @@ -22,9 +22,6 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include -#include #include #include #include diff --git a/gerbview/rs274_read_XY_and_IJ_coordinates.cpp b/gerbview/rs274_read_XY_and_IJ_coordinates.cpp index 5e4976557f..ac71137156 100644 --- a/gerbview/rs274_read_XY_and_IJ_coordinates.cpp +++ b/gerbview/rs274_read_XY_and_IJ_coordinates.cpp @@ -22,8 +22,6 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include #include // for KiROUND #include diff --git a/gerbview/rs274d.cpp b/gerbview/rs274d.cpp index efb1a536bb..2f8f3c7729 100644 --- a/gerbview/rs274d.cpp +++ b/gerbview/rs274d.cpp @@ -26,9 +26,6 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include - #include #include #include diff --git a/gerbview/rs274x.cpp b/gerbview/rs274x.cpp index 8c824362b6..4727a1ea5a 100644 --- a/gerbview/rs274x.cpp +++ b/gerbview/rs274x.cpp @@ -26,9 +26,6 @@ * @file rs274x.cpp */ -#include -#include -#include #include #include // for KiROUND diff --git a/gerbview/toolbars_gerber.cpp b/gerbview/toolbars_gerber.cpp index c5511f644c..4c4068569d 100644 --- a/gerbview/toolbars_gerber.cpp +++ b/gerbview/toolbars_gerber.cpp @@ -19,9 +19,6 @@ * with this program. If not, see . */ -#include - -#include #include #include #include