From 17cf2466aad99adb70ff1a6f7cd49aeea816189d Mon Sep 17 00:00:00 2001 From: Jon Evans Date: Sun, 27 Dec 2020 19:42:04 -0500 Subject: [PATCH] Fix overlapping definitions warning --- pcbnew/plugins/kicad/kicad_plugin.cpp | 4 ++-- pcbnew/plugins/kicad/kicad_plugin.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pcbnew/plugins/kicad/kicad_plugin.cpp b/pcbnew/plugins/kicad/kicad_plugin.cpp index 770967cac0..9b552f2edd 100644 --- a/pcbnew/plugins/kicad/kicad_plugin.cpp +++ b/pcbnew/plugins/kicad/kicad_plugin.cpp @@ -1392,14 +1392,14 @@ void PCB_IO::format( PAD* aPad, int aNestLevel ) const std::string output; // Unconnected pad is default net so don't save it. - if( !( m_ctl & CTL_OMIT_NETS ) && aPad->GetNetCode() != NETINFO_LIST::UNCONNECTED ) + if( !( m_ctl & CTL_OMIT_PAD_NETS ) && aPad->GetNetCode() != NETINFO_LIST::UNCONNECTED ) StrPrintf( &output, " (net %d %s)", m_mapping->Translate( aPad->GetNetCode() ), m_out->Quotew( aPad->GetNetname() ).c_str() ); // Add pinfunction, if exists. // Pin function is closely related to nets, so if CTL_OMIT_NETS is set, // omit also pin function (for instance when saved from library editor) - if( !(m_ctl & CTL_OMIT_NETS) && !aPad->GetPinFunction().IsEmpty() ) + if( !( m_ctl & CTL_OMIT_PAD_NETS ) && !aPad->GetPinFunction().IsEmpty() ) StrPrintf( &output, " (pinfunction %s)", m_out->Quotew( aPad->GetPinFunction() ).c_str() ); diff --git a/pcbnew/plugins/kicad/kicad_plugin.h b/pcbnew/plugins/kicad/kicad_plugin.h index 66f71d1120..848e21af32 100644 --- a/pcbnew/plugins/kicad/kicad_plugin.h +++ b/pcbnew/plugins/kicad/kicad_plugin.h @@ -96,7 +96,7 @@ class PCB_TEXT; #define BOARD_FILE_HOST_VERSION 20200825 ///< Earlier files than this include the host tag -#define CTL_OMIT_NETS (1 << 1) ///< Omit pads net names (useless in library) +#define CTL_OMIT_PAD_NETS (1 << 1) ///< Omit pads net names (useless in library) #define CTL_OMIT_TSTAMPS (1 << 2) ///< Omit component time stamp (useless in library) #define CTL_OMIT_INITIAL_COMMENTS (1 << 3) ///< omit FOOTPRINT initial comments #define CTL_OMIT_PATH (1 << 4) ///< Omit component sheet time stamp (useless in library) @@ -115,7 +115,7 @@ class PCB_TEXT; /// Format output for a footprint library instead of clipboard or BOARD #define CTL_FOR_LIBRARY \ - ( CTL_OMIT_NETS | CTL_OMIT_TSTAMPS | CTL_OMIT_PATH | CTL_OMIT_AT | CTL_OMIT_LIBNAME ) + ( CTL_OMIT_PAD_NETS | CTL_OMIT_TSTAMPS | CTL_OMIT_PATH | CTL_OMIT_AT | CTL_OMIT_LIBNAME ) /// The zero arg constructor when PCB_IO is used for PLUGIN::Load() and PLUGIN::Save()ing /// a BOARD file underneath IO_MGR.