diff --git a/kicad/dialogs/dialog_template_selector.h b/kicad/dialogs/dialog_template_selector.h index 74b14e06fb..93a03eaca2 100644 --- a/kicad/dialogs/dialog_template_selector.h +++ b/kicad/dialogs/dialog_template_selector.h @@ -2,7 +2,7 @@ * This program source code file is part of KiCad, a free EDA CAD application. * * Copyright (C) 2012 Brian Sidebotham - * Copyright (C) 1992-2012 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 @@ -106,7 +106,7 @@ public: private: - void SetHtml( wxFileName aFilename ) + void SetHtml( const wxFileName& aFilename ) { m_htmlWin->LoadPage( aFilename.GetFullPath() ); } diff --git a/kicad/import_project.cpp b/kicad/import_project.cpp index 62a6ab6216..4f9d043607 100644 --- a/kicad/import_project.cpp +++ b/kicad/import_project.cpp @@ -1,7 +1,7 @@ /* * This program source code file is part of KiCad, a free EDA CAD application. * - * Copyright (C) 2017 KiCad Developers, see AUTHORS.txt for contributors. + * Copyright (C) 2017-2018 KiCad Developers, see AUTHORS.txt for contributors. * @author Russell Oliver * * This program is free software; you can redistribute it and/or @@ -130,7 +130,7 @@ void KICAD_MANAGER_FRAME::OnImportEagleFiles( wxCommandEvent& event ) { schframe = Kiway.Player( FRAME_SCH, true ); } - catch( IO_ERROR err ) + catch( const IO_ERROR& err ) { wxMessageBox( _( "Eeschema failed to load:\n" ) + err.What(), _( "KiCad Error" ), wxOK | wxICON_ERROR, this ); @@ -139,7 +139,8 @@ void KICAD_MANAGER_FRAME::OnImportEagleFiles( wxCommandEvent& event ) } schframe->Kiway().ExpressMail( FRAME_SCH, MAIL_IMPORT_FILE, - wxString::Format( "%d\n%s", SCH_IO_MGR::SCH_EAGLE, sch.GetFullPath() ).ToStdString(), this ); + wxString::Format( "%d\n%s", SCH_IO_MGR::SCH_EAGLE, + sch.GetFullPath() ).ToStdString(), this ); if( !schframe->IsShown() ) // the frame exists, (created by the dialog field editor) // but no project loaded. diff --git a/kicad/mainframe.cpp b/kicad/mainframe.cpp index 21d6fda52f..899815b38f 100644 --- a/kicad/mainframe.cpp +++ b/kicad/mainframe.cpp @@ -3,7 +3,7 @@ * * Copyright (C) 2017 Jean-Pierre Charras, jp.charras at wanadoo.fr * Copyright (C) 2013 CERN (www.cern.ch) - * Copyright (C) 2004-2017 KiCad Developers, see change_log.txt for contributors. + * Copyright (C) 2004-2018 KiCad Developers, see change_log.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 @@ -311,7 +311,7 @@ void KICAD_MANAGER_FRAME::RunEeschema( const wxString& aProjectSchematicFileName { frame = Kiway.Player( FRAME_SCH, true ); } - catch( IO_ERROR err ) + catch( const IO_ERROR& err ) { wxMessageBox( _( "Eeschema failed to load:\n" ) + err.What(), _( "KiCad Error" ), wxOK | wxICON_ERROR, this ); @@ -358,7 +358,7 @@ void KICAD_MANAGER_FRAME::OnRunSchLibEditor( wxCommandEvent& event ) { frame = Kiway.Player( FRAME_SCH_LIB_EDITOR, true ); } - catch( IO_ERROR err ) + catch( const IO_ERROR& err ) { wxMessageBox( _( "Component library editor failed to load:\n" ) + err.What(), _( "KiCad Error" ), wxOK | wxICON_ERROR, this ); @@ -384,7 +384,7 @@ void KICAD_MANAGER_FRAME::RunPcbNew( const wxString& aProjectBoardFileName ) { frame = Kiway.Player( FRAME_PCB, true ); } - catch( IO_ERROR err ) + catch( const IO_ERROR& err ) { wxMessageBox( _( "Pcbnew failed to load:\n" ) + err.What(), _( "KiCad Error" ), wxOK | wxICON_ERROR, this ); @@ -430,7 +430,7 @@ void KICAD_MANAGER_FRAME::OnRunPcbFpEditor( wxCommandEvent& event ) { frame = Kiway.Player( FRAME_PCB_MODULE_EDITOR, true ); } - catch( IO_ERROR err ) + catch( const IO_ERROR& err ) { wxMessageBox( _( "Footprint library editor failed to load:\n" ) + err.What(), _( "KiCad Error" ), wxOK | wxICON_ERROR, this ); diff --git a/lib_dxf/drw_entities.h b/lib_dxf/drw_entities.h index a8e7f75a95..50ab4acf4a 100644 --- a/lib_dxf/drw_entities.h +++ b/lib_dxf/drw_entities.h @@ -647,7 +647,7 @@ public: } } - void addVertex( DRW_Vertex v ) + void addVertex( const DRW_Vertex& v ) { DRW_Vertex* vert = new DRW_Vertex();