From 2e8367a40ae3d5f563cef73b8a3679eae2fbffde Mon Sep 17 00:00:00 2001 From: Mike Williams Date: Mon, 5 May 2025 10:35:08 -0400 Subject: [PATCH] sch groups: don't allow drag selecting table cells in un-entered group Fixes: https://gitlab.com/kicad/code/kicad/-/issues/20834 --- eeschema/tools/sch_selection_tool.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/eeschema/tools/sch_selection_tool.cpp b/eeschema/tools/sch_selection_tool.cpp index 212500019c..ab49e6ddbc 100644 --- a/eeschema/tools/sch_selection_tool.cpp +++ b/eeschema/tools/sch_selection_tool.cpp @@ -668,7 +668,10 @@ int SCH_SELECTION_TOOL::Main( const TOOL_EVENT& aEvent ) { m_toolMgr->RunAction( SCH_ACTIONS::move ); } - else if( CollectHits( collector, evt->DragOrigin(), { SCH_TABLECELL_T } ) ) + // Allow drag selecting table cells, except when they're inside a group that we haven't entered + else if( CollectHits( collector, evt->DragOrigin(), { SCH_TABLECELL_T } ) + && ( collector[0]->GetParent()->GetParentGroup() == nullptr + || collector[0]->GetParent()->GetParentGroup() == m_enteredGroup ) ) { selectTableCells( static_cast( collector[0]->GetParent() ) ); }