Fix compile warnings

Some simple warnings and also a deprecation warning from wx
because they felt that a function should be renamed...
This commit is contained in:
Ian McInerney 2021-03-23 19:46:49 +00:00
parent 41f88dbabc
commit a94a481574
4 changed files with 19 additions and 11 deletions

View File

@ -108,7 +108,11 @@ wxString GetVersionInfoData( const wxString& aTitle, bool aHtml, bool aBrief )
aMsg << eol;
aMsg << "Platform: " << wxGetOsDescription() << ", "
#if wxCHECK_VERSION( 3, 1, 5 )
<< platform.GetBitnessName() << ", "
#else
<< platform.GetArchName() << ", "
#endif
<< platform.GetEndiannessName() << ", "
<< platform.GetPortIdName();

View File

@ -99,7 +99,12 @@ static void buildKicadAboutBanner( EDA_BASE_FRAME* aParent, ABOUT_APP_INFO& aInf
wxPlatformInfo platformInfo;
libVersion << "Platform: " << wxGetOsDescription() << ", " << platformInfo.GetArchName();
libVersion << "Platform: " << wxGetOsDescription() << ", "
#if wxCHECK_VERSION( 3, 1, 5 )
<< platformInfo.GetBitnessName();
#else
<< platformInfo.GetArchName();
#endif
aInfo.SetLibVersion( libVersion );

View File

@ -213,10 +213,10 @@ static void insideCourtyard( LIBEVAL::CONTEXT* aCtx, void* self )
if( i != board->m_InsideCourtyardCache.end() )
return i->second;
bool result = insideFootprintCourtyard( item, itemBBox, shape, context, footprint );
bool res = insideFootprintCourtyard( item, itemBBox, shape, context, footprint );
board->m_InsideCourtyardCache[ key ] = result;
return result;
board->m_InsideCourtyardCache[ key ] = res;
return res;
};
if( arg->AsString() == "A" )
@ -290,11 +290,11 @@ static void insideFrontCourtyard( LIBEVAL::CONTEXT* aCtx, void* self )
if( i != board->m_InsideFCourtyardCache.end() )
return i->second;
bool result = insideFootprintCourtyard( item, itemBBox, shape, context, footprint,
bool res = insideFootprintCourtyard( item, itemBBox, shape, context, footprint,
F_Cu );
board->m_InsideFCourtyardCache[ key ] = result;
return result;
board->m_InsideFCourtyardCache[ key ] = res;
return res;
};
if( arg->AsString() == "A" )
@ -368,11 +368,11 @@ static void insideBackCourtyard( LIBEVAL::CONTEXT* aCtx, void* self )
if( i != board->m_InsideBCourtyardCache.end() )
return i->second;
bool result = insideFootprintCourtyard( item, itemBBox, shape, context, footprint,
bool res = insideFootprintCourtyard( item, itemBBox, shape, context, footprint,
B_Cu );
board->m_InsideBCourtyardCache[ key ] = result;
return result;
board->m_InsideBCourtyardCache[ key ] = res;
return res;
};
if( arg->AsString() == "A" )

View File

@ -136,7 +136,6 @@ std::unique_ptr<ZONE> ZONE_CREATE_HELPER::createZoneFromExisting( const ZONE& aS
void ZONE_CREATE_HELPER::performZoneCutout( ZONE& aZone, const ZONE& aCutout )
{
BOARD_COMMIT commit( &m_tool );
BOARD* board = m_tool.getModel<BOARD>();
std::vector<ZONE*> newZones;
// Clear the selection before removing the old zone