Fix typo.
And clean up the code just a little to make it clearer. Fixes https://gitlab.com/kicad/code/kicad/issues/12022
This commit is contained in:
parent
1278b2916c
commit
1ade5a8c72
|
@ -787,13 +787,18 @@ const EDA_RECT FOOTPRINT::GetBoundingBox( bool aIncludeText, bool aIncludeInvisi
|
||||||
|
|
||||||
for( BOARD_ITEM* item : m_drawings )
|
for( BOARD_ITEM* item : m_drawings )
|
||||||
{
|
{
|
||||||
// We want the bitmap bounding box just in the footprint editor
|
if( m_privateLayers.test( item->GetLayer() ) && !isFPEdit )
|
||||||
// so it will start with the correct initial zoom
|
continue;
|
||||||
if( !isFPEdit
|
|
||||||
&& ( m_privateLayers.test( item->GetLayer() ) || item->Type() != PCB_BITMAP_T ) )
|
// We want the bitmap bounding box just in the footprint editor
|
||||||
|
// so it will start with the correct initial zoom
|
||||||
|
if( item->Type() == PCB_BITMAP_T && !isFPEdit )
|
||||||
|
continue;
|
||||||
|
|
||||||
|
// Handle text separately
|
||||||
|
if( item->Type() == PCB_FP_TEXT_T )
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if( item->Type() != PCB_FP_TEXT_T )
|
|
||||||
area.Merge( item->GetBoundingBox() );
|
area.Merge( item->GetBoundingBox() );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue