From 8be213e36fd6dd23b7128e3a33249c2250f9e5be Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Sun, 21 Mar 2021 11:24:55 +0000 Subject: [PATCH] Trim includes (and use consistent terminology in error messages). --- pcbnew/router/length_tuner_tool.cpp | 11 ----------- pcbnew/router/pns_arc.cpp | 4 ---- pcbnew/router/pns_arc.h | 1 - pcbnew/router/pns_component_dragger.cpp | 1 - pcbnew/router/pns_component_dragger.h | 4 ---- pcbnew/router/pns_diff_pair.cpp | 8 -------- pcbnew/router/pns_diff_pair.h | 3 --- pcbnew/router/pns_diff_pair_placer.cpp | 6 ------ pcbnew/router/pns_diff_pair_placer.h | 3 --- pcbnew/router/pns_dp_meander_placer.cpp | 1 - pcbnew/router/pns_kicad_iface.cpp | 13 +++---------- pcbnew/router/pns_line.cpp | 1 - pcbnew/router/pns_logger.cpp | 9 --------- pcbnew/router/pns_meander.cpp | 1 - pcbnew/router/pns_meander_placer.h | 2 -- pcbnew/router/pns_meander_placer_base.h | 2 -- pcbnew/router/pns_mouse_trail_tracer.h | 1 - pcbnew/router/pns_node.h | 4 ---- pcbnew/router/pns_optimizer.cpp | 1 - pcbnew/router/pns_router.h | 6 ------ pcbnew/router/pns_tool_base.cpp | 11 +---------- pcbnew/router/pns_tune_status_popup.h | 2 +- pcbnew/router/router_preview_item.cpp | 2 -- pcbnew/router/router_preview_item.h | 3 +-- 24 files changed, 6 insertions(+), 94 deletions(-) diff --git a/pcbnew/router/length_tuner_tool.cpp b/pcbnew/router/length_tuner_tool.cpp index 77853dfa9a..cd44879c6a 100644 --- a/pcbnew/router/length_tuner_tool.cpp +++ b/pcbnew/router/length_tuner_tool.cpp @@ -19,21 +19,10 @@ * with this program. If not, see . */ -#include - #include "class_draw_panel_gal.h" -#include "board.h" - -#include -#include -#include -#include -#include #include -#include #include #include -#include "pns_segment.h" #include "pns_router.h" #include "pns_meander_placer.h" // fixme: move settings to separate header #include "pns_tune_status_popup.h" diff --git a/pcbnew/router/pns_arc.cpp b/pcbnew/router/pns_arc.cpp index c9b30b939c..6489c9043b 100644 --- a/pcbnew/router/pns_arc.cpp +++ b/pcbnew/router/pns_arc.cpp @@ -20,11 +20,7 @@ #include "pns_arc.h" #include "pns_node.h" -#include "pns_router.h" #include "pns_utils.h" -#include "pns_via.h" - -#include namespace PNS { diff --git a/pcbnew/router/pns_arc.h b/pcbnew/router/pns_arc.h index 57b9183a66..f22b40adee 100644 --- a/pcbnew/router/pns_arc.h +++ b/pcbnew/router/pns_arc.h @@ -24,7 +24,6 @@ #include #include -#include #include #include "pns_line.h" diff --git a/pcbnew/router/pns_component_dragger.cpp b/pcbnew/router/pns_component_dragger.cpp index 012282d602..311bc3f007 100644 --- a/pcbnew/router/pns_component_dragger.cpp +++ b/pcbnew/router/pns_component_dragger.cpp @@ -22,7 +22,6 @@ #include "pns_line.h" #include "pns_solid.h" -#include "pns_via.h" #include "pns_router.h" #include "pns_component_dragger.h" diff --git a/pcbnew/router/pns_component_dragger.h b/pcbnew/router/pns_component_dragger.h index 049938a362..d04d705ba3 100644 --- a/pcbnew/router/pns_component_dragger.h +++ b/pcbnew/router/pns_component_dragger.h @@ -24,10 +24,6 @@ #include #include "pns_drag_algo.h" -#include "pns_itemset.h" -#include "pns_line.h" -#include "pns_node.h" -#include "pns_via.h" namespace PNS { diff --git a/pcbnew/router/pns_diff_pair.cpp b/pcbnew/router/pns_diff_pair.cpp index d8bfb4495c..6520506adb 100644 --- a/pcbnew/router/pns_diff_pair.cpp +++ b/pcbnew/router/pns_diff_pair.cpp @@ -24,18 +24,10 @@ #include #include -#include -#include #include -#include -#include - #include "pns_diff_pair.h" #include "pns_router.h" -#include "pns_solid.h" -#include "pns_utils.h" -#include "pns_debug_decorator.h" namespace PNS { diff --git a/pcbnew/router/pns_diff_pair.h b/pcbnew/router/pns_diff_pair.h index 65680c16d8..b9e3666cb0 100644 --- a/pcbnew/router/pns_diff_pair.h +++ b/pcbnew/router/pns_diff_pair.h @@ -25,9 +25,6 @@ #include -#include -#include - #include "pns_line.h" #include "pns_via.h" #include "pns_link_holder.h" diff --git a/pcbnew/router/pns_diff_pair_placer.cpp b/pcbnew/router/pns_diff_pair_placer.cpp index 7afd386270..25ff16f17b 100644 --- a/pcbnew/router/pns_diff_pair_placer.cpp +++ b/pcbnew/router/pns_diff_pair_placer.cpp @@ -19,14 +19,8 @@ * with this program. If not, see . */ -#include -#include -#include - -#include "pns_node.h" #include "pns_walkaround.h" #include "pns_shove.h" -#include "pns_utils.h" #include "pns_router.h" #include "pns_diff_pair_placer.h" #include "pns_solid.h" diff --git a/pcbnew/router/pns_diff_pair_placer.h b/pcbnew/router/pns_diff_pair_placer.h index 8a14377ec6..57a2660604 100644 --- a/pcbnew/router/pns_diff_pair_placer.h +++ b/pcbnew/router/pns_diff_pair_placer.h @@ -25,9 +25,6 @@ #include -#include -#include - #include "pns_sizes_settings.h" #include "pns_node.h" #include "pns_via.h" diff --git a/pcbnew/router/pns_dp_meander_placer.cpp b/pcbnew/router/pns_dp_meander_placer.cpp index b2000f660f..517834cb5c 100644 --- a/pcbnew/router/pns_dp_meander_placer.cpp +++ b/pcbnew/router/pns_dp_meander_placer.cpp @@ -29,7 +29,6 @@ #include "pns_dp_meander_placer.h" #include "pns_diff_pair.h" #include "pns_router.h" -#include "pns_utils.h" namespace PNS { diff --git a/pcbnew/router/pns_kicad_iface.cpp b/pcbnew/router/pns_kicad_iface.cpp index ae249d33e5..a2a4a59399 100644 --- a/pcbnew/router/pns_kicad_iface.cpp +++ b/pcbnew/router/pns_kicad_iface.cpp @@ -32,10 +32,6 @@ #include #include -#include -#include -#include - #include #include @@ -50,8 +46,6 @@ #include -#include "tools/pcb_tool_base.h" - #include "pns_kicad_iface.h" #include "pns_arc.h" @@ -1007,10 +1001,9 @@ bool PNS_KICAD_IFACE_BASE::syncZone( PNS::NODE* aWorld, ZONE* aZone, SHAPE_POLY_ KIDIALOG dlg( nullptr, wxString::Format( _( "%s is malformed." ), aZone->GetSelectMenuText( units ) ), KIDIALOG::KD_WARNING ); - dlg.ShowDetailedText( wxString::Format( _( "This zone cannot be handled by the track " - "layout tool.\n" - "Please verify it is not a " - "self-intersecting polygon." ) ) ); + dlg.ShowDetailedText( wxString::Format( _( "This zone cannot be handled by the router.\n" + "Please verify it is not a self-intersecting " + "polygon." ) ) ); dlg.DoNotShowCheckbox( __FILE__, __LINE__ ); dlg.ShowModal(); diff --git a/pcbnew/router/pns_line.cpp b/pcbnew/router/pns_line.cpp index 746167e657..ec9a7df2ee 100644 --- a/pcbnew/router/pns_line.cpp +++ b/pcbnew/router/pns_line.cpp @@ -28,7 +28,6 @@ #include "pns_node.h" #include "pns_via.h" #include "pns_utils.h" -#include "pns_router.h" #include diff --git a/pcbnew/router/pns_logger.cpp b/pcbnew/router/pns_logger.cpp index 61b52ae90e..0f95735414 100644 --- a/pcbnew/router/pns_logger.cpp +++ b/pcbnew/router/pns_logger.cpp @@ -22,15 +22,6 @@ #include "pns_logger.h" #include "pns_item.h" #include "pns_via.h" -#include "pns_line.h" -#include "pns_segment.h" -#include "pns_solid.h" - -#include -#include -#include -#include -#include namespace PNS { diff --git a/pcbnew/router/pns_meander.cpp b/pcbnew/router/pns_meander.cpp index 2943d1aaeb..5e46394367 100644 --- a/pcbnew/router/pns_meander.cpp +++ b/pcbnew/router/pns_meander.cpp @@ -23,7 +23,6 @@ #include "pns_node.h" #include "pns_itemset.h" -#include "pns_topology.h" #include "pns_meander.h" #include "pns_meander_placer_base.h" #include "pns_router.h" diff --git a/pcbnew/router/pns_meander_placer.h b/pcbnew/router/pns_meander_placer.h index 8d5e7fea7b..7fd319e641 100644 --- a/pcbnew/router/pns_meander_placer.h +++ b/pcbnew/router/pns_meander_placer.h @@ -25,11 +25,9 @@ #include -#include #include #include "pns_node.h" -#include "pns_via.h" #include "pns_line.h" #include "pns_placement_algo.h" #include "pns_meander.h" diff --git a/pcbnew/router/pns_meander_placer_base.h b/pcbnew/router/pns_meander_placer_base.h index 0d02d60898..aff4f29efc 100644 --- a/pcbnew/router/pns_meander_placer_base.h +++ b/pcbnew/router/pns_meander_placer_base.h @@ -25,11 +25,9 @@ #include -#include #include #include "pns_node.h" -#include "pns_via.h" #include "pns_line.h" #include "pns_placement_algo.h" #include "pns_meander.h" diff --git a/pcbnew/router/pns_mouse_trail_tracer.h b/pcbnew/router/pns_mouse_trail_tracer.h index 41a542fcd3..ffa19bc4e7 100644 --- a/pcbnew/router/pns_mouse_trail_tracer.h +++ b/pcbnew/router/pns_mouse_trail_tracer.h @@ -24,7 +24,6 @@ #include #include -#include #include namespace PNS { diff --git a/pcbnew/router/pns_node.h b/pcbnew/router/pns_node.h index b250ad794c..a8dbd0e484 100644 --- a/pcbnew/router/pns_node.h +++ b/pcbnew/router/pns_node.h @@ -26,12 +26,8 @@ #include #include #include -#include - -#include #include -#include #include #include diff --git a/pcbnew/router/pns_optimizer.cpp b/pcbnew/router/pns_optimizer.cpp index 513e1a3ced..d052f3346f 100644 --- a/pcbnew/router/pns_optimizer.cpp +++ b/pcbnew/router/pns_optimizer.cpp @@ -22,7 +22,6 @@ #include #include #include -#include #include diff --git a/pcbnew/router/pns_router.h b/pcbnew/router/pns_router.h index b688f3cb62..c959208dce 100644 --- a/pcbnew/router/pns_router.h +++ b/pcbnew/router/pns_router.h @@ -23,18 +23,12 @@ #define __PNS_ROUTER_H #include - #include #include - -#include -#include #include #include "pns_routing_settings.h" #include "pns_sizes_settings.h" -#include "pns_item.h" -#include "pns_itemset.h" #include "pns_node.h" namespace KIGFX diff --git a/pcbnew/router/pns_tool_base.cpp b/pcbnew/router/pns_tool_base.cpp index 51efb9a6a4..2ed02e70e1 100644 --- a/pcbnew/router/pns_tool_base.cpp +++ b/pcbnew/router/pns_tool_base.cpp @@ -23,24 +23,15 @@ #include using namespace std::placeholders; -#include -#include #include #include #include -#include -#include -#include "pns_arc.h" #include "pns_kicad_iface.h" #include "pns_tool_base.h" -#include "pns_segment.h" +#include "pns_arc.h" #include "pns_solid.h" -#include "pns_via.h" -#include "pns_router.h" -#include "pns_meander_placer.h" // fixme: move settings to separate header -#include "pns_topology.h" using namespace KIGFX; diff --git a/pcbnew/router/pns_tune_status_popup.h b/pcbnew/router/pns_tune_status_popup.h index b2a14774d8..1a399d099e 100644 --- a/pcbnew/router/pns_tune_status_popup.h +++ b/pcbnew/router/pns_tune_status_popup.h @@ -37,7 +37,7 @@ class ROUTER; class PNS_TUNE_STATUS_POPUP : public STATUS_TEXT_POPUP { public: - PNS_TUNE_STATUS_POPUP( EDA_DRAW_FRAME* aParent ) : + PNS_TUNE_STATUS_POPUP( wxWindow* aParent ) : STATUS_TEXT_POPUP( aParent ) { } diff --git a/pcbnew/router/router_preview_item.cpp b/pcbnew/router/router_preview_item.cpp index 8e574a147e..c34b1bbcfc 100644 --- a/pcbnew/router/router_preview_item.cpp +++ b/pcbnew/router/router_preview_item.cpp @@ -21,11 +21,9 @@ #include #include -#include #include #include -#include "track.h" #include #include "router_preview_item.h" diff --git a/pcbnew/router/router_preview_item.h b/pcbnew/router/router_preview_item.h index e639c84c27..4a4dca9c7a 100644 --- a/pcbnew/router/router_preview_item.h +++ b/pcbnew/router/router_preview_item.h @@ -35,9 +35,8 @@ #include #include -#include -#include +#include namespace PNS {