From f17c4cceac54d06f01dff4e7c9a2862beff34cb0 Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Sat, 9 Dec 2023 14:54:05 +0000 Subject: [PATCH] Back-port bugfix from master. Fixes https://gitlab.com/kicad/code/kicad/-/issues/16315 --- pcbnew/tools/pcb_selection_tool.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/pcbnew/tools/pcb_selection_tool.cpp b/pcbnew/tools/pcb_selection_tool.cpp index 4a5c79252b..e0f2523284 100644 --- a/pcbnew/tools/pcb_selection_tool.cpp +++ b/pcbnew/tools/pcb_selection_tool.cpp @@ -2603,7 +2603,12 @@ bool PCB_SELECTION_TOOL::Selectable( const BOARD_ITEM* aItem, bool checkVisibili case PCB_DIM_CENTER_T: case PCB_DIM_RADIAL_T: case PCB_DIM_ORTHOGONAL_T: - if( aItem->GetParentFootprint() ) + if( m_isFootprintEditor ) + { + if( !view()->IsLayerVisible( aItem->GetLayer() ) ) + return false; + } + else if( aItem->GetParentFootprint() ) { // Footprint dimension selections are only allowed in footprint editor mode. if( !checkVisibilityOnly )