Skip to content

Commit 16d36d7

Browse files
committed
add in the single layer inside a group case
1 parent a94a974 commit 16d36d7

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

editor/src/messages/tool/common_functionality/shape_editor.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -501,8 +501,9 @@ impl ShapeState {
501501
return;
502502
}
503503

504-
// Check if this layer itself has children (is a merged/grouped layer created with Cmd+G)
505-
let is_grouped = layer1.has_children(document.metadata());
504+
// Check if this layer has multiple children (is a merged/grouped layer created with Cmd+G)
505+
let num_children = layer1.children(document.metadata()).count();
506+
let is_grouped = num_children > 1;
506507

507508
if is_grouped {
508509
// Grouped/merged layer: use helper function to handle reorganization

0 commit comments

Comments
 (0)