From 19e3815c855d451ba43762ec149c6e01e6ea32da Mon Sep 17 00:00:00 2001 From: jean-pierre charras Date: Sun, 28 Jan 2018 09:51:28 +0100 Subject: [PATCH] Cvpcb: rename files: fix names in files and remove a old file not used. --- cvpcb/CMakeLists.txt | 12 +-- cvpcb/auto_associate.cpp | 8 +- cvpcb/auto_associate.h | 8 +- cvpcb/cfg.cpp | 2 +- cvpcb/components_listbox.cpp | 4 +- cvpcb/cvpcb.h | 10 +-- cvpcb/cvpcb_mainframe.cpp | 20 +---- cvpcb/cvpcb_mainframe.h | 7 +- cvpcb/dialogs/dialog_cvpcb_config_fbp.h | 100 ----------------------- cvpcb/dialogs/dialog_display_options.cpp | 6 +- cvpcb/display_footprints_frame.cpp | 6 +- cvpcb/display_footprints_frame.h | 2 +- cvpcb/footprints_listbox.cpp | 4 +- cvpcb/library_listbox.cpp | 4 +- cvpcb/listbox_base.cpp | 2 +- cvpcb/listboxes.h | 10 +-- cvpcb/readwrite_dlgs.cpp | 6 +- 17 files changed, 48 insertions(+), 163 deletions(-) delete mode 100644 cvpcb/dialogs/dialog_cvpcb_config_fbp.h diff --git a/cvpcb/CMakeLists.txt b/cvpcb/CMakeLists.txt index 832e2e50bf..b7e9348047 100644 --- a/cvpcb/CMakeLists.txt +++ b/cvpcb/CMakeLists.txt @@ -38,14 +38,14 @@ set( CVPCB_SRCS ../pcbnew/board_items_to_polygon_shape_transform.cpp ../pcbnew/pcb_general_settings.cpp ../pcbnew/class_drc_item.cpp - autosel.cpp + auto_associate.cpp cfg.cpp - class_components_listbox.cpp - class_DisplayFootprintsFrame.cpp - class_footprints_listbox.cpp - class_library_listbox.cpp + components_listbox.cpp + display_footprints_frame.cpp + footprints_listbox.cpp + library_listbox.cpp cvpcb_mainframe.cpp - listboxes.cpp + listbox_base.cpp menubar.cpp readwrite_dlgs.cpp tool_cvpcb.cpp diff --git a/cvpcb/auto_associate.cpp b/cvpcb/auto_associate.cpp index 21a173bfc3..c3757a2343 100644 --- a/cvpcb/auto_associate.cpp +++ b/cvpcb/auto_associate.cpp @@ -1,7 +1,7 @@ /* * This program source code file is part of KiCad, a free EDA CAD application. * - * Copyright (C) 1992-2017 KiCad Developers, see AUTHORS.txt for contributors. + * Copyright (C) 1992-2018 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 @@ */ /** - * @file autosel.cpp + * @file auto_associate.cpp */ // This file handle automatic selection of footprints, from .equ files which give @@ -42,8 +42,8 @@ #include #include -#include -#include +#include +#include #define QUOTE '\'' diff --git a/cvpcb/auto_associate.h b/cvpcb/auto_associate.h index d329c0871e..e3076957ef 100644 --- a/cvpcb/auto_associate.h +++ b/cvpcb/auto_associate.h @@ -1,7 +1,7 @@ /* * This program source code file is part of KiCad, a free EDA CAD application. * - * Copyright (C) 1992-2016 KiCad Developers, see AUTHORS.txt for contributors. + * Copyright (C) 1992-2018 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,8 +21,8 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ -#ifndef AUTOSEL_H -#define AUTOSEL_H +#ifndef AUTO_ASSOCIATE_H +#define AUTO_ASSOCIATE_H // A helper class to handle info read in .equ files, which gives a footprint LIB_ID // corresponding to a component value. @@ -42,4 +42,4 @@ public: typedef boost::ptr_vector< FOOTPRINT_EQUIVALENCE > FOOTPRINT_EQUIVALENCE_LIST; -#endif // ifndef AUTOSEL_H +#endif // ifndef AUTO_ASSOCIATE_H diff --git a/cvpcb/cfg.cpp b/cvpcb/cfg.cpp index 740776b2df..4ce1b7f072 100644 --- a/cvpcb/cfg.cpp +++ b/cvpcb/cfg.cpp @@ -39,7 +39,7 @@ #include #include -#include +#include PARAM_CFG_ARRAY& CVPCB_MAINFRAME::GetProjectFileParameters() diff --git a/cvpcb/components_listbox.cpp b/cvpcb/components_listbox.cpp index d5944aff29..4da5c47776 100644 --- a/cvpcb/components_listbox.cpp +++ b/cvpcb/components_listbox.cpp @@ -1,7 +1,7 @@ /* * This program source code file is part of KiCad, a free EDA CAD application. * - * Copyright (C) 1992-2016 KiCad Developers, see AUTHORS.txt for contributors. + * Copyright (C) 1992-2018 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 @@ -30,7 +30,7 @@ #include #include -#include +#include #include diff --git a/cvpcb/cvpcb.h b/cvpcb/cvpcb.h index 79dac6ebc7..5592125128 100644 --- a/cvpcb/cvpcb.h +++ b/cvpcb/cvpcb.h @@ -1,8 +1,8 @@ /* * This program source code file is part of KiCad, a free EDA CAD application. * - * Copyright (C) 2007 Jean-Pierre Charras, jp.charras at wanadoo.fr - * Copyright (C) 2014 KiCad Developers, see CHANGELOG.TXT for contributors. + * Copyright (C) 2018 Jean-Pierre Charras, jp.charras at wanadoo.fr + * Copyright (C) 2018 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,10 +25,8 @@ #ifndef __CVPCB_H__ #define __CVPCB_H__ -// config for footprints doc file access -#define DEFAULT_FOOTPRINTS_LIST_FILENAME wxT( "footprints_doc/footprints.pdf" ) - -// Define print format to display a schematic component line +// Define print format to display a schematic component line. format: +// idx reference - value : footprint_id #define CMP_FORMAT wxT( "%3d %8s - %16s : %s" ) extern const wxString EquFileExtension; diff --git a/cvpcb/cvpcb_mainframe.cpp b/cvpcb/cvpcb_mainframe.cpp index 5115c5e982..eea81a20b2 100644 --- a/cvpcb/cvpcb_mainframe.cpp +++ b/cvpcb/cvpcb_mainframe.cpp @@ -1,7 +1,7 @@ /* * This program source code file is part of KiCad, a free EDA CAD application. * - * Copyright (C) 2016 Jean-Pierre Charras, jp.charras at wanadoo.fr + * Copyright (C) 2018 Jean-Pierre Charras, jp.charras at wanadoo.fr * Copyright (C) 2011-2016 Wayne Stambaugh * Copyright (C) 1992-2018 KiCad Developers, see AUTHORS.txt for contributors. * @@ -45,9 +45,9 @@ #include #include -#include +#include #include -#include +#include #include @@ -57,11 +57,9 @@ wxSize const FRAME_DEFAULT_SIZE_DU( 500, 250 ); ///@{ /// \ingroup config -/// Nonzero iff cvpcb should be kept open after saving files +/// Nonzero if cvpcb should be kept open after saving association in schematic static const wxString KeepCvpcbOpenEntry = "KeepCvpcbOpen"; -static const wxString FootprintDocFileEntry = "footprints_doc_file"; - static const wxString FilterFootprintEntry = "FilterFootprint"; ///@} @@ -128,13 +126,6 @@ CVPCB_MAINFRAME::CVPCB_MAINFRAME( KIWAY* aKiway, wxWindow* aParent ) : m_tcFilterString = NULL; m_FootprintsList = FOOTPRINT_LIST::GetInstance( Kiway() ); - /* Name of the document footprint list - * usually located in share/modules/footprints_doc - * this is of the responsibility to users to create this file - * if they want to have a list of footprints - */ - m_DocModulesFileName = DEFAULT_FOOTPRINTS_LIST_FILENAME; - // Give an icon wxIcon icon; icon.CopyFromBitmap( KiBitmap( icon_cvpcb_xpm ) ); @@ -211,8 +202,6 @@ void CVPCB_MAINFRAME::LoadSettings( wxConfigBase* aCfg ) EDA_BASE_FRAME::LoadSettings( aCfg ); aCfg->Read( KeepCvpcbOpenEntry, &m_keepCvpcbOpen, true ); - aCfg->Read( FootprintDocFileEntry, &m_DocModulesFileName, - DEFAULT_FOOTPRINTS_LIST_FILENAME ); aCfg->Read( FilterFootprintEntry, &m_filteringOptions, FOOTPRINTS_LISTBOX::UNFILTERED_FP_LIST ); } @@ -222,7 +211,6 @@ void CVPCB_MAINFRAME::SaveSettings( wxConfigBase* aCfg ) EDA_BASE_FRAME::SaveSettings( aCfg ); aCfg->Write( KeepCvpcbOpenEntry, m_keepCvpcbOpen ); - aCfg->Write( FootprintDocFileEntry, m_DocModulesFileName ); aCfg->Write( FilterFootprintEntry, m_filteringOptions ); } diff --git a/cvpcb/cvpcb_mainframe.h b/cvpcb/cvpcb_mainframe.h index 87d4ba1e7c..5b22f2d5e7 100644 --- a/cvpcb/cvpcb_mainframe.h +++ b/cvpcb/cvpcb_mainframe.h @@ -1,8 +1,8 @@ /* * This program source code file is part of KiCad, a free EDA CAD application. * - * Copyright (C) 2016 Jean-Pierre Charras, jp.charras at wanadoo.fr - * Copyright (C) 1992-2017 KiCad Developers, see AUTHORS.txt for contributors. + * Copyright (C) 2018 Jean-Pierre Charras, jp.charras at wanadoo.fr + * Copyright (C) 1992-2018 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 @@ -36,7 +36,7 @@ #include #include -#include +#include #include @@ -72,7 +72,6 @@ class CVPCB_MAINFRAME : public KIWAY_PLAYER public: wxArrayString m_ModuleLibNames; wxArrayString m_EquFilesNames; - wxString m_DocModulesFileName; std::unique_ptr m_FootprintsList; protected: diff --git a/cvpcb/dialogs/dialog_cvpcb_config_fbp.h b/cvpcb/dialogs/dialog_cvpcb_config_fbp.h deleted file mode 100644 index 7481dcded4..0000000000 --- a/cvpcb/dialogs/dialog_cvpcb_config_fbp.h +++ /dev/null @@ -1,100 +0,0 @@ -/////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Apr 10 2012) -// http://www.wxformbuilder.org/ -// -// PLEASE DO "NOT" EDIT THIS FILE! -/////////////////////////////////////////////////////////////////////////// - -#ifndef __DIALOG_CVPCB_CONFIG_FBP_H__ -#define __DIALOG_CVPCB_CONFIG_FBP_H__ - -#include -#include -#include -#include "dialog_shim.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -/////////////////////////////////////////////////////////////////////////// - -/////////////////////////////////////////////////////////////////////////////// -/// Class DIALOG_CVPCB_CONFIG_FBP -/////////////////////////////////////////////////////////////////////////////// -class DIALOG_CVPCB_CONFIG_FBP : public DIALOG_SHIM -{ - private: - - protected: - enum - { - ID_ADD_LIB = 1000, - ID_INSERT_LIB, - ID_REMOVE_LIB, - ID_LIB_UP, - ID_LIB_DOWN, - ID_ADD_EQU, - ID_INSERT_EQU, - ID_REMOVE_EQU, - ID_EQU_UP, - ID_EQU_DOWN, - ID_BROWSE_MOD_DOC, - ID_LIB_PATH_SEL, - ID_INSERT_PATH, - ID_REMOVE_PATH - }; - - wxListBox* m_ListLibr; - wxButton* m_buttonAddLib; - wxButton* m_buttonInsLib; - wxButton* m_buttonRemoveLib; - wxButton* m_buttonLibUp; - wxButton* m_buttonLibDown; - wxListBox* m_ListEquiv; - wxButton* m_buttonAddEqu; - wxButton* m_buttonInsEqu; - wxButton* m_buttonRemoveEqu; - wxButton* m_buttonEquUp; - wxButton* m_buttonEquDown; - wxTextCtrl* m_TextHelpModulesFileName; - wxButton* m_buttonModDoc; - wxListBox* m_listUserPaths; - wxButton* m_buttonAddPath; - wxButton* m_buttonInsPath; - wxButton* m_buttonRemovePath; - wxListBox* m_DefaultLibraryPathslistBox; - wxStaticLine* m_staticline2; - wxStdDialogButtonSizer* m_sdbSizer2; - wxButton* m_sdbSizer2OK; - wxButton* m_sdbSizer2Cancel; - - // Virtual event handlers, overide them in your derived class - virtual void OnCloseWindow( wxCloseEvent& event ) { event.Skip(); } - virtual void OnAddOrInsertLibClick( wxCommandEvent& event ) { event.Skip(); } - virtual void OnRemoveLibClick( wxCommandEvent& event ) { event.Skip(); } - virtual void OnButtonUpClick( wxCommandEvent& event ) { event.Skip(); } - virtual void OnButtonDownClick( wxCommandEvent& event ) { event.Skip(); } - virtual void OnBrowseModDocFile( wxCommandEvent& event ) { event.Skip(); } - virtual void OnAddOrInsertPath( wxCommandEvent& event ) { event.Skip(); } - virtual void OnRemoveUserPath( wxCommandEvent& event ) { event.Skip(); } - virtual void OnCancelClick( wxCommandEvent& event ) { event.Skip(); } - virtual void OnOkClick( wxCommandEvent& event ) { event.Skip(); } - - - public: - - DIALOG_CVPCB_CONFIG_FBP( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = wxEmptyString, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 570,625 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER ); - ~DIALOG_CVPCB_CONFIG_FBP(); - -}; - -#endif //__DIALOG_CVPCB_CONFIG_FBP_H__ diff --git a/cvpcb/dialogs/dialog_display_options.cpp b/cvpcb/dialogs/dialog_display_options.cpp index 20db40e8b6..19f9b9a929 100644 --- a/cvpcb/dialogs/dialog_display_options.cpp +++ b/cvpcb/dialogs/dialog_display_options.cpp @@ -1,7 +1,7 @@ /* * This program source code file is part of KiCad, a free EDA CAD application. * - * Copyright (C) 1992-2016 KiCad Developers, see AUTHORS.txt for contributors. + * Copyright (C) 1992-2018 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 @@ -31,8 +31,8 @@ #include #include #include -#include -#include +#include +#include #include diff --git a/cvpcb/display_footprints_frame.cpp b/cvpcb/display_footprints_frame.cpp index e50dfd41d1..c7a2bc23d1 100644 --- a/cvpcb/display_footprints_frame.cpp +++ b/cvpcb/display_footprints_frame.cpp @@ -24,7 +24,7 @@ */ /** - * @file class_DisplayFootprintsFrame.cpp + * @file display_footprints_frame.cpp */ #include @@ -44,9 +44,9 @@ #include #include -#include +#include #include -#include +#include #include <3d_viewer/eda_3d_viewer.h> diff --git a/cvpcb/display_footprints_frame.h b/cvpcb/display_footprints_frame.h index 7b674cb16e..19c98ed9c0 100644 --- a/cvpcb/display_footprints_frame.h +++ b/cvpcb/display_footprints_frame.h @@ -23,7 +23,7 @@ */ /** - * @file class_DisplayFootprintsFrame.h + * @file display_footprints_frame.h */ diff --git a/cvpcb/footprints_listbox.cpp b/cvpcb/footprints_listbox.cpp index 304d3567e0..3679fc15b1 100644 --- a/cvpcb/footprints_listbox.cpp +++ b/cvpcb/footprints_listbox.cpp @@ -23,7 +23,7 @@ */ /** - * @file class_footprints_listbox.cpp + * @file footprints_listbox.cpp * class to display the list of available footprints */ @@ -33,7 +33,7 @@ #include #include -#include +#include #include #include #include diff --git a/cvpcb/library_listbox.cpp b/cvpcb/library_listbox.cpp index 0615c8c3b7..8a449fed7a 100644 --- a/cvpcb/library_listbox.cpp +++ b/cvpcb/library_listbox.cpp @@ -22,7 +22,7 @@ */ /** - * @file class_library_listbox.cpp + * @file library_listbox.cpp * class to display used library and selecting it */ @@ -32,7 +32,7 @@ #include #include -#include +#include #include diff --git a/cvpcb/listbox_base.cpp b/cvpcb/listbox_base.cpp index 61fc11005a..37d6508ef7 100644 --- a/cvpcb/listbox_base.cpp +++ b/cvpcb/listbox_base.cpp @@ -32,7 +32,7 @@ #include #include -#include +#include #include diff --git a/cvpcb/listboxes.h b/cvpcb/listboxes.h index 9ebb51c340..f6ee8bc4ca 100644 --- a/cvpcb/listboxes.h +++ b/cvpcb/listboxes.h @@ -1,7 +1,7 @@ /* * This program source code file is part of KiCad, a free EDA CAD application. * - * Copyright (C) 1992-2017 KiCad Developers, see AUTHORS.txt for contributors. + * Copyright (C) 1992-2018 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,11 +22,11 @@ */ /** - * @file listview_classes.h + * @file listboxes.h */ -#ifndef CVSTRUCT_H -#define CVSTRUCT_H +#ifndef LISTBOXES_H +#define LISTBOXES_H #include #include @@ -244,4 +244,4 @@ public: }; -#endif //#ifndef CVSTRUCT_H +#endif //#ifndef LISTBOXES_H diff --git a/cvpcb/readwrite_dlgs.cpp b/cvpcb/readwrite_dlgs.cpp index c0449c0a57..4eca962207 100644 --- a/cvpcb/readwrite_dlgs.cpp +++ b/cvpcb/readwrite_dlgs.cpp @@ -5,9 +5,9 @@ /* * This program source code file is part of KiCad, a free EDA CAD application. * - * Copyright (C) 2015 Jean-Pierre Charras, jean-pierre.charras + * Copyright (C) 2018 Jean-Pierre Charras, jean-pierre.charras * Copyright (C) 2011-2016 Wayne Stambaugh - * Copyright (C) 1992-2017 KiCad Developers, see AUTHORS.txt for contributors. + * Copyright (C) 1992-2018 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 @@ -39,7 +39,7 @@ #include #include -#include +#include #include #include