Fix minor compil and Coverity warnings.
This commit is contained in:
parent
c16d0603c6
commit
0604d7b813
|
@ -49,7 +49,8 @@ public:
|
|||
|
||||
EE_COLLECTOR( const KICAD_T* aScanTypes = EE_COLLECTOR::AllItems ) :
|
||||
m_Unit( 0 ),
|
||||
m_Convert( 0 )
|
||||
m_Convert( 0 ),
|
||||
m_ShowPinElectricalTypes( false )
|
||||
{
|
||||
SetScanTypes( aScanTypes );
|
||||
}
|
||||
|
|
|
@ -1886,14 +1886,14 @@ int SCH_EDIT_TOOL::ChangeTextType( const TOOL_EVENT& aEvent )
|
|||
auto prepareForNetName =
|
||||
[]( wxString& aText )
|
||||
{
|
||||
wxString txt = aText;
|
||||
txt.Replace( "\n", "_" );
|
||||
txt.Replace( "\r", "_" );
|
||||
txt.Replace( "\t", "_" );
|
||||
txt.Replace( " ", "_" );
|
||||
wxString local_txt = aText;
|
||||
local_txt.Replace( "\n", "_" );
|
||||
local_txt.Replace( "\r", "_" );
|
||||
local_txt.Replace( "\t", "_" );
|
||||
local_txt.Replace( " ", "_" );
|
||||
|
||||
// label strings are "escaped" i.e. a '/' is replaced by "{slash}"
|
||||
return EscapeString( txt, CTX_NETNAME );
|
||||
return EscapeString( local_txt, CTX_NETNAME );
|
||||
};
|
||||
|
||||
switch( convertTo )
|
||||
|
|
|
@ -76,7 +76,7 @@ PCB_BITMAP& PCB_BITMAP::operator=( const BOARD_ITEM& aItem )
|
|||
delete m_image;
|
||||
m_image = new BITMAP_BASE( *bitmap->m_image );
|
||||
m_pos = bitmap->m_pos;
|
||||
m_image->SetPixelSizeIu( Mils2iu( 1000 ) / m_image->GetPPI() );
|
||||
m_image->SetPixelSizeIu( (float) Mils2iu( 1000 ) / m_image->GetPPI() );
|
||||
}
|
||||
|
||||
return *this;
|
||||
|
|
Loading…
Reference in New Issue