Re-allows selection of bitmaps not owned by a footprint.

It was broken by my commit f8051d95
Fixes #13747
https://gitlab.com/kicad/code/kicad/issues/13747
This commit is contained in:
jean-pierre charras 2023-02-02 18:09:37 +01:00
parent 8b03c093f9
commit fcefb5f86d
1 changed files with 10 additions and 2 deletions

View File

@ -2,7 +2,7 @@
* This program source code file is part of KiCad, a free EDA CAD application. * This program source code file is part of KiCad, a free EDA CAD application.
* *
* Copyright (C) 2013-2017 CERN * Copyright (C) 2013-2017 CERN
* Copyright (C) 2018-2022 KiCad Developers, see AUTHORS.txt for contributors. * Copyright (C) 2018-2023 KiCad Developers, see AUTHORS.txt for contributors.
* @author Tomasz Wlostowski <tomasz.wlostowski@cern.ch> * @author Tomasz Wlostowski <tomasz.wlostowski@cern.ch>
* @author Maciej Suminski <maciej.suminski@cern.ch> * @author Maciej Suminski <maciej.suminski@cern.ch>
* *
@ -2246,9 +2246,17 @@ bool PCB_SELECTION_TOOL::itemPassesFilter( BOARD_ITEM* aItem, bool aMultiSelect
break; break;
case PCB_BITMAP_T: case PCB_BITMAP_T:
if( !m_filter.graphics || !m_isFootprintEditor ) // a bitmap living in a footprint must not be selected inside the board editor
if( !m_filter.graphics )
return false; return false;
if( !m_isFootprintEditor )
{
if( dynamic_cast<FOOTPRINT*>( aItem->GetParent() ) )
return false;
}
break; break;
case PCB_FP_TEXT_T: case PCB_FP_TEXT_T: