Move headers from common folders to appropriate include folders round 1.

This commit is contained in:
Wayne Stambaugh 2020-12-17 08:12:18 -05:00
parent 211866d602
commit 08cf9a1e20
40 changed files with 68 additions and 52 deletions

View File

@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include <dialog_locked_items_query.h>
#include <dialogs/dialog_locked_items_query.h>
#include <bitmaps.h>
DIALOG_LOCKED_ITEMS_QUERY::DIALOG_LOCKED_ITEMS_QUERY( wxWindow* aParent, int aLockedItemCount ) :

View File

@ -24,7 +24,7 @@
#include <base_screen.h>
#include <confirm.h>
#include <core/arraydim.h>
#include <dialog_page_settings.h>
#include <dialogs/dialog_page_settings.h>
#include <eda_draw_frame.h>
#include <eda_item.h>
#include <gr_basic.h>

View File

@ -1,5 +1,6 @@
/*
* Copyright (C) 2018 CERN
* Copyright (C) 2020 KiCad Developers, see AUTHORS.txt for contributors.
* Author: Maciej Suminski <maciej.suminski@cern.ch>
*
* This program is free software: you can redistribute it and/or modify it
@ -16,7 +17,7 @@
* with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "dialog_print_generic.h"
#include <dialogs/dialog_print_generic.h>
#include <confirm.h>
#include <eda_draw_frame.h>
@ -27,6 +28,7 @@
static constexpr double MIN_SCALE = 0.01;
static constexpr double MAX_SCALE = 100.0;
DIALOG_PRINT_GENERIC::DIALOG_PRINT_GENERIC( EDA_DRAW_FRAME* aParent, PRINTOUT_SETTINGS* aSettings )
: DIALOG_PRINT_GENERIC_BASE( aParent ),
m_config( nullptr ),
@ -246,6 +248,7 @@ void DIALOG_PRINT_GENERIC::onPrintButtonClick( wxCommandEvent& event )
auto printout = std::unique_ptr<wxPrintout>( createPrintout( _( "Print" ) ) );
Pgm().m_Printing = true;
{
if( !printer.Print( this, printout.get(), true ) )
{
@ -257,6 +260,7 @@ void DIALOG_PRINT_GENERIC::onPrintButtonClick( wxCommandEvent& event )
*s_PrintData = printer.GetPrintDialogData().GetPrintData();
}
}
Pgm().m_Printing = false;
}

View File

@ -1,7 +1,7 @@
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2018 KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 2018-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
@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include <dialog_text_entry.h>
#include <dialogs/dialog_text_entry.h>
WX_TEXT_ENTRY_DIALOG::WX_TEXT_ENTRY_DIALOG( wxWindow* aParent,

View File

@ -1,7 +1,7 @@
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2019 KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 2019-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 as published by the
@ -22,10 +22,11 @@
#include <widgets/gal_options_panel.h>
#include <widgets/paged_dialog.h>
#include <panel_gal_display_options.h>
#include <dialogs/panel_gal_display_options.h>
PANEL_GAL_DISPLAY_OPTIONS::PANEL_GAL_DISPLAY_OPTIONS( EDA_DRAW_FRAME* aFrame, PAGED_DIALOG* aParent ) :
PANEL_GAL_DISPLAY_OPTIONS::PANEL_GAL_DISPLAY_OPTIONS( EDA_DRAW_FRAME* aFrame,
PAGED_DIALOG* aParent ) :
wxPanel( aParent->GetTreebook(), wxID_ANY ),
m_frame( aFrame )
{

View File

@ -24,7 +24,7 @@
#include <widgets/paged_dialog.h>
#include <widgets/ui_common.h>
#include <rc_item.h>
#include "panel_setup_severities.h"
#include <dialogs/panel_setup_severities.h>
#include <wx/radiobut.h>

View File

@ -1,7 +1,7 @@
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2018 KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 2018-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
@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include <grid_color_swatch_helpers.h>
#include <widgets/grid_color_swatch_helpers.h>
#include <settings/color_settings.h>
#include <dialogs/dialog_color_picker.h>

View File

@ -2,7 +2,7 @@
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2014 Henner Zeller <h.zeller@acm.org>
* Copyright (C) 2014-2019 KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 2014-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
@ -22,7 +22,7 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include "lib_tree.h"
#include <widgets/lib_tree.h>
#include <macros.h>
#include <wxdataviewctrl_helpers.h>
#include <wx/artprov.h>

View File

@ -1,7 +1,7 @@
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2018 KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 2018-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
@ -24,7 +24,7 @@
#include <wx/tokenzr.h>
#include <wx/dc.h>
#include <wx/wx.h>
#include "wx_grid.h"
#include <widgets/wx_grid.h>
#include <algorithm>
@ -73,6 +73,7 @@ void WX_GRID::SetTable( wxGridTableBase* aTable, bool aTakeOwnership )
formBuilderColWidths[ i ] = GetColSize( i );
wxGrid::SetTable( aTable );
// wxGrid::SetTable() may change the number of columns, so prevent out-of-bounds access
// to formBuilderColWidths
numberCols = std::min( numberCols, GetNumberCols() );
@ -116,6 +117,7 @@ wxString WX_GRID::GetShownColumns()
{
if( shownColumns.Length() )
shownColumns << wxT( " " );
shownColumns << i;
}
}
@ -242,7 +244,8 @@ int WX_GRID::GetVisibleWidth( int aCol, bool aHeader, bool aContents, bool aKeep
if( aKeep )
size = GetRowLabelSize();
// The 1.1 scale factor is due to the fact row labels use a bold font, bigger than the normal font
// The 1.1 scale factor is due to the fact row labels use a bold font, bigger than
// the normal font.
// TODO: use a better way to evaluate the text size, for bold font
for( int row = 0; aContents && row < GetNumberRows(); row++ )
size = std::max( size, int( GetTextExtent( GetRowLabelValue( row ) + "M" ).x * 1.1 ) );
@ -252,12 +255,14 @@ int WX_GRID::GetVisibleWidth( int aCol, bool aHeader, bool aContents, bool aKeep
if( aKeep )
size = GetColSize( aCol );
// 'M' is generally the widest character, so we buffer the column width by default to ensure
// we don't write a continuous line of text at the column header
// 'M' is generally the widest character, so we buffer the column width by default to
// ensure we don't write a continuous line of text at the column header
if( aHeader )
{
EnsureColLabelsVisible();
// The 1.1 scale factor is due to the fact headers use a bold font, bigger than the normal font
// The 1.1 scale factor is due to the fact headers use a bold font, bigger than
// the normal font.
size = std::max( size, int( GetTextExtent( GetColLabelValue( aCol ) + "M" ).x * 1.1 ) );
}

View File

@ -24,7 +24,7 @@
#include <bitmaps.h>
#include <class_libentry.h>
#include <confirm.h>
#include <dialog_text_entry.h>
#include <dialogs/dialog_text_entry.h>
#include <kiway.h>
#include <symbol_edit_frame.h>
#include <symbol_library_manager.h>

View File

@ -23,7 +23,7 @@
#include <kiface_i.h>
#include <dialog_sch_import_settings.h>
#include <dialogs/panel_setup_netclasses.h>
#include <panel_setup_severities.h>
#include <dialogs/panel_setup_severities.h>
#include <panel_setup_formatting.h>
#include <panel_setup_pinmap.h>
#include <erc_item.h>

View File

@ -32,7 +32,7 @@
#include <dialogs/dialog_schematic_setup.h>
#include <kiway.h>
#include <symbol_edit_frame.h>
#include <panel_gal_display_options.h>
#include <dialogs/panel_gal_display_options.h>
#include <panel_hotkeys_editor.h>
#include <pgm_base.h>
#include <project/project_file.h>

View File

@ -2,7 +2,7 @@
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2010-2016 Jean-Pierre Charras jp.charras at wanadoo.fr
* Copyright (C) 1992-2016 KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 1992-2020 KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 2018 CERN
* Author: Maciej Suminski <maciej.suminski@cern.ch>
*

View File

@ -19,7 +19,7 @@
#ifndef DIALOG_PRINT_GENERIC_H
#define DIALOG_PRINT_GENERIC_H
#include "dialog_print_generic_base.h"
#include <dialogs/dialog_print_generic_base.h>
#include <wx/valnum.h>
#include <widgets/unit_binder.h>

View File

@ -36,7 +36,7 @@
#include <page_layout/ws_data_item.h>
#include <page_layout/ws_data_model.h>
#include <page_layout/ws_painter.h>
#include <dialog_page_settings.h>
#include <dialogs/dialog_page_settings.h>
#include "invoke_pl_editor_dialog.h"
#include "pl_editor_frame.h"

View File

@ -31,7 +31,7 @@
#include <page_layout/ws_data_item.h>
#include <page_layout/ws_data_model.h>
#include <widgets/paged_dialog.h>
#include <panel_gal_display_options.h>
#include <dialogs/panel_gal_display_options.h>
#include <panel_hotkeys_editor.h>
#include <confirm.h>
#include <kiplatform/app.h>

View File

@ -2,7 +2,7 @@
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2019 CERN
* Copyright (C) 2019 KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 2019-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,7 +27,7 @@
#include <tool/tool_manager.h>
#include <confirm.h>
#include <bitmaps.h>
#include <dialog_page_settings.h>
#include <dialogs/dialog_page_settings.h>
#include <page_layout/ws_data_model.h>
#include <page_layout/ws_painter.h>
@ -38,6 +38,7 @@
#include "tools/pl_editor_control.h"
#include "tools/pl_selection_tool.h"
bool PL_EDITOR_CONTROL::Init()
{
m_frame = getEditFrame<PL_EDITOR_FRAME>();

View File

@ -1,7 +1,7 @@
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2017-2019 KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 2017-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 as published by the
@ -29,7 +29,7 @@
#include <drc/drc_item.h>
#include <dialog_import_settings.h>
#include <io_mgr.h>
#include <panel_setup_severities.h>
#include <dialogs/panel_setup_severities.h>
#include <panel_text_variables.h>
#include <project.h>
#include <project/project_file.h>
@ -41,7 +41,8 @@
#include "panel_setup_rules.h"
DIALOG_BOARD_SETUP::DIALOG_BOARD_SETUP( PCB_EDIT_FRAME* aFrame ) :
PAGED_DIALOG( aFrame, _( "Board Setup" ), false, _( "Import Settings from Another Board..." ) ),
PAGED_DIALOG( aFrame, _( "Board Setup" ), false,
_( "Import Settings from Another Board..." ) ),
m_frame( aFrame )
{
BOARD* board = aFrame->GetBoard();

View File

@ -4,7 +4,7 @@
* Copyright (C) 2018 Jean-Pierre Charras, jp.charras at wanadoo.fr
* Copyright (C) 2015 Dick Hollenbeck, dick@softplc.com
* Copyright (C) 2008 Wayne Stambaugh <stambaughw@gmail.com>
* Copyright (C) 2004-2019 KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 2004-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
@ -25,7 +25,7 @@
*/
#include <confirm.h>
#include <dialog_text_entry.h>
#include <dialogs/dialog_text_entry.h>
#include <3d_viewer/eda_3d_viewer.h>
#include <pcb_edit_frame.h>
#include <validators.h>

View File

@ -30,7 +30,7 @@
#include <board_design_settings.h>
#include <footprint.h>
#include <confirm.h>
#include <dialog_text_entry.h>
#include <dialogs/dialog_text_entry.h>
#include <filename_resolver.h>
#include <pcb_edit_frame.h>
#include <pcbnew_settings.h>

View File

@ -2,7 +2,7 @@
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2010-2016 Jean-Pierre Charras, jean-pierre.charras at wanadoo.fr
* Copyright (C) 1992-2019 KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 1992-2020 KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 2018 CERN
* Author: Maciej Suminski <maciej.suminski@cern.ch>
*
@ -34,7 +34,7 @@
#include <tool/tool_manager.h>
#include <tools/pcb_actions.h>
#include <tools/pcb_control.h>
#include <dialog_print_generic.h>
#include <dialogs/dialog_print_generic.h>
#include <pcbnew_printout.h>
class DIALOG_PRINT_PCBNEW : public DIALOG_PRINT_GENERIC
@ -112,7 +112,8 @@ DIALOG_PRINT_PCBNEW::DIALOG_PRINT_PCBNEW( PCB_BASE_EDIT_FRAME* aParent,
createExtraOptions();
createLeftPanel();
m_outputMode->Bind( wxEVT_COMMAND_CHOICE_SELECTED, &DIALOG_PRINT_PCBNEW::onColorModeChanged, this );
m_outputMode->Bind( wxEVT_COMMAND_CHOICE_SELECTED, &DIALOG_PRINT_PCBNEW::onColorModeChanged,
this );
}
@ -211,7 +212,8 @@ void DIALOG_PRINT_PCBNEW::createExtraOptions()
wxDefaultPosition, wxDefaultSize, 0 );
optionsSizer->Add( m_checkUseTheme, wxGBPosition( rows++, 0 ), wxGBSpan( 1, 3 ), wxALL, 5 );
m_checkUseTheme->Bind( wxEVT_COMMAND_CHECKBOX_CLICKED, &DIALOG_PRINT_PCBNEW::onUseThemeChecked, this );
m_checkUseTheme->Bind( wxEVT_COMMAND_CHECKBOX_CLICKED,
&DIALOG_PRINT_PCBNEW::onUseThemeChecked, this );
wxArrayString m_colorThemeChoices;
m_colorTheme = new wxChoice( sbOptionsSizer->GetStaticBox(), wxID_ANY, wxDefaultPosition,
@ -288,7 +290,8 @@ void DIALOG_PRINT_PCBNEW::createLeftPanel()
// Select/Unselect all buttons
m_buttonSelectAll = new wxButton( sbLayersSizer->GetStaticBox(), wxID_ANY, _( "Select all" ) );
m_buttonDeselectAll = new wxButton( sbLayersSizer->GetStaticBox(), wxID_ANY, _( "Deselect all" ) );
m_buttonDeselectAll = new wxButton( sbLayersSizer->GetStaticBox(), wxID_ANY,
_( "Deselect all" ) );
m_buttonSelectAll->Connect( wxEVT_COMMAND_BUTTON_CLICKED,
wxCommandEventHandler( DIALOG_PRINT_PCBNEW::onSelectAllClick ), NULL, this );
@ -301,7 +304,8 @@ void DIALOG_PRINT_PCBNEW::createLeftPanel()
// Exclude Edge.Pcb layer checkbox
m_checkboxNoEdge = new wxCheckBox( sbLayersSizer->GetStaticBox(), wxID_ANY, _( "Exclude PCB edge layer" ) );
m_checkboxNoEdge = new wxCheckBox( sbLayersSizer->GetStaticBox(), wxID_ANY,
_( "Exclude PCB edge layer" ) );
m_checkboxNoEdge->SetToolTip( _("Exclude contents of Edges_Pcb layer from all other layers") );
// Static box sizer layout

View File

@ -1,7 +1,7 @@
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2019 KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 2019-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
@ -24,7 +24,7 @@
#include <pcb_edit_frame.h>
#include <board_design_settings.h>
#include <dialog_text_entry.h>
#include <dialogs/dialog_text_entry.h>
#include <panel_setup_mask_and_paste.h>
@ -32,7 +32,8 @@ PANEL_SETUP_MASK_AND_PASTE::PANEL_SETUP_MASK_AND_PASTE( PAGED_DIALOG* aParent,
PCB_EDIT_FRAME* aFrame ) :
PANEL_SETUP_MASK_AND_PASTE_BASE( aParent->GetTreebook() ),
m_maskMargin( aFrame, m_MaskMarginLabel, m_MaskMarginCtrl, m_MaskMarginUnits, true ),
m_maskMinWidth( aFrame, m_MaskMinWidthLabel, m_MaskMinWidthCtrl, m_MaskMinWidthUnits, true ),
m_maskMinWidth( aFrame, m_MaskMinWidthLabel, m_MaskMinWidthCtrl, m_MaskMinWidthUnits,
true ),
m_pasteMargin( aFrame, m_PasteMarginLabel, m_PasteMarginCtrl, m_PasteMarginUnits, true )
{
m_Frame = aFrame;
@ -68,7 +69,6 @@ bool PANEL_SETUP_MASK_AND_PASTE::TransferDataToWindow()
bool PANEL_SETUP_MASK_AND_PASTE::TransferDataFromWindow()
{
// These are all stored in project file, not board, so no need for OnModify()
m_BrdSettings->m_SolderMaskMargin = m_maskMargin.GetValue();
m_BrdSettings->m_SolderMaskMinWidth = m_maskMinWidth.GetValue();

View File

@ -31,7 +31,7 @@
#include <filter_reader.h>
#include <fp_lib_table.h>
#include <validators.h>
#include <dialog_text_entry.h>
#include <dialogs/dialog_text_entry.h>
#include <tool/tool_manager.h>
#include <tools/pcb_actions.h>
#include <board.h>

View File

@ -24,7 +24,7 @@
#include <footprint.h>
#include <confirm.h>
#include <dialog_text_entry.h>
#include <dialogs/dialog_text_entry.h>
#include <microwave/microwave_tool.h>
#include <trigo.h>

View File

@ -29,7 +29,7 @@
#include <fp_shape.h>
#include <footprint.h>
#include <confirm.h>
#include <dialog_text_entry.h>
#include <dialogs/dialog_text_entry.h>
#include <geometry/geometry_utils.h>
#include <math/util.h> // for KiROUND
#include <microwave/microwave_tool.h>

View File

@ -3,7 +3,7 @@
*
* Copyright (C) 2015 Jean-Pierre Charras, jp.charras at wanadoo.fr
* Copyright (C) 2012 SoftPLC Corporation, Dick Hollenbeck <dick@softplc.com>
* Copyright (C) 2015-2016 Wayne Stambaugh <stambaughw@verizon.net>
* Copyright (C) 2015-2016 Wayne Stambaugh <stambaughw@gmail.com>
* Copyright (C) 1992-2020 KiCad Developers, see AUTHORS.txt for contributors.
*
* This program is free software; you can redistribute it and/or
@ -35,7 +35,7 @@
#include <filter_reader.h>
#include <base_units.h>
#include <validators.h>
#include <dialog_text_entry.h>
#include <dialogs/dialog_text_entry.h>
#include <board.h>
#include <footprint.h>
#include <fp_shape.h>

View File

@ -39,7 +39,7 @@ using namespace std::placeholders;
#include <collectors.h>
#include <dialog_find.h>
#include <dialog_filter_selection.h>
#include <dialog_locked_items_query.h>
#include <dialogs/dialog_locked_items_query.h>
#include <class_draw_panel_gal.h>
#include <view/view_controls.h>
#include <preview_items/selection_area.h>