Skip to content

Commit 528a579

Browse files
adamgerhantKeavon
authored andcommitted
Code cleanup
1 parent b5fb868 commit 528a579

File tree

8 files changed

+61
-74
lines changed

8 files changed

+61
-74
lines changed

editor/src/messages/portfolio/document/document_message_handler.rs

Lines changed: 7 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -182,20 +182,13 @@ impl MessageHandler<DocumentMessage, DocumentMessageContext<'_>> for DocumentMes
182182
device_pixel_ratio,
183183
} = context;
184184

185-
let selected_nodes_bounding_box_viewport = self.network_interface.selected_nodes_bounding_box_viewport(&self.breadcrumb_network_path);
186-
let selected_visible_layers_bounding_box_viewport = self.selected_visible_layers_bounding_box_viewport();
187185
match message {
188186
// Sub-messages
189187
DocumentMessage::Navigation(message) => {
190188
let context = NavigationMessageContext {
191189
network_interface: &mut self.network_interface,
192190
breadcrumb_network_path: &self.breadcrumb_network_path,
193191
ipp,
194-
selection_bounds: if self.graph_view_overlay_open {
195-
selected_nodes_bounding_box_viewport
196-
} else {
197-
selected_visible_layers_bounding_box_viewport
198-
},
199192
document_ptz: &mut self.document_ptz,
200193
graph_view_overlay_open: self.graph_view_overlay_open,
201194
preferences,
@@ -259,7 +252,7 @@ impl MessageHandler<DocumentMessage, DocumentMessageContext<'_>> for DocumentMes
259252
AlignAxis::X => DVec2::X,
260253
AlignAxis::Y => DVec2::Y,
261254
};
262-
let Some(combined_box) = self.selected_visible_layers_bounding_box_viewport() else {
255+
let Some(combined_box) = self.network_interface.selected_layers_artwork_bounding_box_viewport() else {
263256
return;
264257
};
265258

@@ -486,7 +479,7 @@ impl MessageHandler<DocumentMessage, DocumentMessageContext<'_>> for DocumentMes
486479
FlipAxis::X => DVec2::new(-1., 1.),
487480
FlipAxis::Y => DVec2::new(1., -1.),
488481
};
489-
if let Some([min, max]) = self.selected_visible_and_unlock_layers_bounding_box_viewport() {
482+
if let Some([min, max]) = self.network_interface.selected_unlocked_layers_bounding_box_viewport() {
490483
let center = (max + min) / 2.;
491484
let bbox_trans = DAffine2::from_translation(-center);
492485
let mut added_transaction = false;
@@ -506,7 +499,7 @@ impl MessageHandler<DocumentMessage, DocumentMessageContext<'_>> for DocumentMes
506499
}
507500
DocumentMessage::RotateSelectedLayers { degrees } => {
508501
// Get the bounding box of selected layers in viewport space
509-
if let Some([min, max]) = self.selected_visible_and_unlock_layers_bounding_box_viewport() {
502+
if let Some([min, max]) = self.network_interface.selected_unlocked_layers_bounding_box_viewport() {
510503
// Calculate the center of the bounding box to use as rotation pivot
511504
let center = (max + min) / 2.;
512505
// Transform that moves pivot point to origin
@@ -1063,13 +1056,13 @@ impl MessageHandler<DocumentMessage, DocumentMessageContext<'_>> for DocumentMes
10631056
self.selected_layers_reorder(relative_index_offset, responses);
10641057
}
10651058
DocumentMessage::ClipLayer { id } => {
1066-
let layer = LayerNodeIdentifier::new(id, &self.network_interface, &[]);
1059+
let layer = LayerNodeIdentifier::new(id, &self.network_interface);
10671060

10681061
responses.add(DocumentMessage::AddTransaction);
10691062
responses.add(GraphOperationMessage::ClipModeToggle { layer });
10701063
}
10711064
DocumentMessage::SelectLayer { id, ctrl, shift } => {
1072-
let layer = LayerNodeIdentifier::new(id, &self.network_interface, &[]);
1065+
let layer = LayerNodeIdentifier::new(id, &self.network_interface);
10731066

10741067
let mut nodes = vec![];
10751068

@@ -1266,7 +1259,7 @@ impl MessageHandler<DocumentMessage, DocumentMessageContext<'_>> for DocumentMes
12661259
responses.add(OverlaysMessage::Draw);
12671260
}
12681261
DocumentMessage::ToggleLayerExpansion { id, recursive } => {
1269-
let layer = LayerNodeIdentifier::new(id, &self.network_interface, &[]);
1262+
let layer = LayerNodeIdentifier::new(id, &self.network_interface);
12701263
let metadata = self.metadata();
12711264

12721265
let is_collapsed = self.collapsed.0.contains(&layer);
@@ -1323,7 +1316,7 @@ impl MessageHandler<DocumentMessage, DocumentMessageContext<'_>> for DocumentMes
13231316
self.network_interface.document_network().nodes.contains_key(node_id))
13241317
.filter_map(|(node_id, click_targets)| {
13251318
self.network_interface.is_layer(&node_id, &[]).then(|| {
1326-
let layer = LayerNodeIdentifier::new(node_id, &self.network_interface, &[]);
1319+
let layer = LayerNodeIdentifier::new(node_id, &self.network_interface);
13271320
(layer, click_targets)
13281321
})
13291322
})
@@ -1708,31 +1701,6 @@ impl DocumentMessageHandler {
17081701
.last()
17091702
}
17101703

1711-
/// Get the combined bounding box of the click targets of the selected visible layers in viewport space
1712-
pub fn selected_visible_layers_bounding_box_viewport(&self) -> Option<[DVec2; 2]> {
1713-
self.network_interface
1714-
.selected_nodes()
1715-
.selected_visible_layers(&self.network_interface)
1716-
.filter_map(|layer| self.metadata().bounding_box_viewport(layer))
1717-
.reduce(graphene_std::renderer::Quad::combine_bounds)
1718-
}
1719-
1720-
pub fn selected_visible_and_unlock_layers_bounding_box_viewport(&self) -> Option<[DVec2; 2]> {
1721-
self.network_interface
1722-
.selected_nodes()
1723-
.selected_visible_and_unlocked_layers(&self.network_interface)
1724-
.filter_map(|layer| self.metadata().bounding_box_viewport(layer))
1725-
.reduce(graphene_std::renderer::Quad::combine_bounds)
1726-
}
1727-
1728-
pub fn selected_visible_and_unlock_layers_bounding_box_document(&self) -> Option<[DVec2; 2]> {
1729-
self.network_interface
1730-
.selected_nodes()
1731-
.selected_visible_and_unlocked_layers(&self.network_interface)
1732-
.map(|layer| self.metadata().nonzero_bounding_box(layer))
1733-
.reduce(graphene_std::renderer::Quad::combine_bounds)
1734-
}
1735-
17361704
pub fn document_network(&self) -> &NodeNetwork {
17371705
self.network_interface.document_network()
17381706
}

editor/src/messages/portfolio/document/graph_operation/graph_operation_message_handler.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ impl MessageHandler<GraphOperationMessage, GraphOperationMessageContext<'_>> for
119119
let primary_input = artboard.inputs.first().expect("Artboard should have a primary input").clone();
120120
if let NodeInput::Node { node_id, .. } = &primary_input {
121121
if network_interface.is_layer(node_id, &[]) && !network_interface.is_artboard(node_id, &[]) {
122-
network_interface.move_layer_to_stack(LayerNodeIdentifier::new(*node_id, network_interface, &[]), artboard_layer, 0, &[]);
122+
network_interface.move_layer_to_stack(LayerNodeIdentifier::new(*node_id, network_interface), artboard_layer, 0, &[]);
123123
} else {
124124
network_interface.disconnect_input(&InputConnector::node(artboard_layer.to_node(), 0), &[]);
125125
network_interface.set_input(&InputConnector::node(id, 0), primary_input, &[]);

editor/src/messages/portfolio/document/graph_operation/utility_types.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ impl<'a> ModifyInputsContext<'a> {
124124
pub fn create_layer(&mut self, new_id: NodeId) -> LayerNodeIdentifier {
125125
let new_merge_node = resolve_document_node_type("Merge").expect("Merge node").default_node_template();
126126
self.network_interface.insert_node(new_id, new_merge_node, &[]);
127-
LayerNodeIdentifier::new(new_id, self.network_interface, &[])
127+
LayerNodeIdentifier::new(new_id, self.network_interface)
128128
}
129129

130130
/// Creates an artboard as the primary export for the document network
@@ -138,7 +138,7 @@ impl<'a> ModifyInputsContext<'a> {
138138
Some(NodeInput::value(TaggedValue::Bool(artboard.clip), false)),
139139
]);
140140
self.network_interface.insert_node(new_id, artboard_node_template, &[]);
141-
LayerNodeIdentifier::new(new_id, self.network_interface, &[])
141+
LayerNodeIdentifier::new(new_id, self.network_interface)
142142
}
143143

144144
pub fn insert_boolean_data(&mut self, operation: graphene_std::path_bool::BooleanOperation, layer: LayerNodeIdentifier) {
@@ -236,7 +236,7 @@ impl<'a> ModifyInputsContext<'a> {
236236
self.layer_node.or_else(|| {
237237
let export_node = self.network_interface.document_network().exports.first().and_then(|export| export.as_node())?;
238238
if self.network_interface.is_layer(&export_node, &[]) {
239-
Some(LayerNodeIdentifier::new(export_node, self.network_interface, &[]))
239+
Some(LayerNodeIdentifier::new(export_node, self.network_interface))
240240
} else {
241241
None
242242
}

editor/src/messages/portfolio/document/navigation/navigation_message_handler.rs

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ pub struct NavigationMessageContext<'a> {
1818
pub network_interface: &'a mut NodeNetworkInterface,
1919
pub breadcrumb_network_path: &'a [NodeId],
2020
pub ipp: &'a InputPreprocessorMessageHandler,
21-
pub selection_bounds: Option<[DVec2; 2]>,
2221
pub document_ptz: &'a mut PTZ,
2322
pub graph_view_overlay_open: bool,
2423
pub preferences: &'a PreferencesMessageHandler,
@@ -39,7 +38,6 @@ impl MessageHandler<NavigationMessage, NavigationMessageContext<'_>> for Navigat
3938
network_interface,
4039
breadcrumb_network_path,
4140
ipp,
42-
selection_bounds,
4341
document_ptz,
4442
graph_view_overlay_open,
4543
preferences,
@@ -386,9 +384,16 @@ impl MessageHandler<NavigationMessage, NavigationMessageContext<'_>> for Navigat
386384
responses.add(DocumentMessage::PTZUpdate);
387385
responses.add(NodeGraphMessage::SetGridAlignedEdges);
388386
}
387+
// Fully zooms in on the selected
389388
NavigationMessage::FitViewportToSelection => {
389+
let selection_bounds = if graph_view_overlay_open {
390+
network_interface.selected_nodes_bounding_box_viewport(breadcrumb_network_path)
391+
} else {
392+
network_interface.selected_layers_artwork_bounding_box_viewport()
393+
};
394+
390395
if let Some(bounds) = selection_bounds {
391-
let Some(ptz) = get_ptz_mut(document_ptz, network_interface, graph_view_overlay_open, breadcrumb_network_path) else {
396+
let Some(ptz) = get_ptz(document_ptz, network_interface, graph_view_overlay_open, breadcrumb_network_path) else {
392397
log::error!("Could not get node graph PTZ in FitViewportToSelection");
393398
return;
394399
};

editor/src/messages/portfolio/document/node_graph/node_graph_message_handler.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2404,19 +2404,19 @@ impl NodeGraphMessageHandler {
24042404
let mut ancestors_of_selected = HashSet::new();
24052405
let mut descendants_of_selected = HashSet::new();
24062406
for selected_layer in &selected_layers {
2407-
for ancestor in LayerNodeIdentifier::new(*selected_layer, network_interface, &[]).ancestors(network_interface.document_metadata()) {
2407+
for ancestor in LayerNodeIdentifier::new(*selected_layer, network_interface).ancestors(network_interface.document_metadata()) {
24082408
if ancestor != LayerNodeIdentifier::ROOT_PARENT && ancestor.to_node() != *selected_layer {
24092409
ancestors_of_selected.insert(ancestor.to_node());
24102410
}
24112411
}
2412-
for descendant in LayerNodeIdentifier::new(*selected_layer, network_interface, &[]).descendants(network_interface.document_metadata()) {
2412+
for descendant in LayerNodeIdentifier::new(*selected_layer, network_interface).descendants(network_interface.document_metadata()) {
24132413
descendants_of_selected.insert(descendant.to_node());
24142414
}
24152415
}
24162416

24172417
for (&node_id, node_metadata) in &network_interface.document_network_metadata().persistent_metadata.node_metadata {
24182418
if node_metadata.persistent_metadata.is_layer() {
2419-
let layer = LayerNodeIdentifier::new(node_id, network_interface, &[]);
2419+
let layer = LayerNodeIdentifier::new(node_id, network_interface);
24202420

24212421
let children_allowed =
24222422
// The layer has other layers as children along the secondary input's horizontal flow

editor/src/messages/portfolio/document/utility_types/document_metadata.rs

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -250,12 +250,8 @@ impl LayerNodeIdentifier {
250250

251251
/// Construct a [`LayerNodeIdentifier`], debug asserting that it is a layer node. This should only be used in the document network since the structure is not loaded in nested networks.
252252
#[track_caller]
253-
pub fn new(node_id: NodeId, network_interface: &NodeNetworkInterface, network_path: &[NodeId]) -> Self {
254-
debug_assert!(
255-
network_interface.is_layer(&node_id, network_path),
256-
"Layer identifier constructed from non-layer node {node_id}: {:#?}",
257-
network_interface.nested_network(network_path).unwrap().nodes.get(&node_id)
258-
);
253+
pub fn new(node_id: NodeId, network_interface: &NodeNetworkInterface) -> Self {
254+
debug_assert!(network_interface.is_layer(&node_id, &[]), "Layer identifier constructed from non-layer node {node_id}",);
259255
Self::new_unchecked(node_id)
260256
}
261257

editor/src/messages/portfolio/document/utility_types/network_interface.rs

Lines changed: 36 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -203,12 +203,12 @@ impl NodeNetworkInterface {
203203
}
204204

205205
/// Returns the first downstream layer(inclusive) from a node. If the node is a layer, it will return itself.
206-
pub fn downstream_layer(&mut self, node_id: &NodeId, network_path: &[NodeId]) -> Option<LayerNodeIdentifier> {
206+
pub fn downstream_layer_for_chain_node(&mut self, node_id: &NodeId, network_path: &[NodeId]) -> Option<NodeId> {
207207
let mut id = *node_id;
208208
while !self.is_layer(&id, network_path) {
209209
id = self.outward_wires(network_path)?.get(&OutputConnector::node(id, 0))?.first()?.node_id()?;
210210
}
211-
Some(LayerNodeIdentifier::new(id, self, network_path))
211+
Some(id)
212212
}
213213

214214
/// Returns all downstream layers (inclusive) from a node. If the node is a layer, it will return itself.
@@ -388,8 +388,8 @@ impl NodeNetworkInterface {
388388
}
389389

390390
// If a chain node does not have a selected downstream layer, then set the position to absolute
391-
let downstream_layer = self.downstream_layer(node_id, network_path);
392-
if downstream_layer.is_none_or(|downstream_layer| new_ids.keys().all(|key| *key != downstream_layer.to_node())) {
391+
let downstream_layer = self.downstream_layer_for_chain_node(node_id, network_path);
392+
if downstream_layer.is_none_or(|downstream_layer| new_ids.keys().all(|key| *key != downstream_layer)) {
393393
let Some(position) = self.position(node_id, network_path) else {
394394
log::error!("Could not get position in create_node_template");
395395
return None;
@@ -1244,7 +1244,7 @@ impl NodeNetworkInterface {
12441244
.as_ref()
12451245
.is_some_and(|reference| reference == "Artboard" && self.connected_to_output(node_id, &[]) && self.is_layer(node_id, &[]))
12461246
{
1247-
Some(LayerNodeIdentifier::new(*node_id, self, &[]))
1247+
Some(LayerNodeIdentifier::new(*node_id, self))
12481248
} else {
12491249
None
12501250
}
@@ -3025,7 +3025,7 @@ impl NodeNetworkInterface {
30253025

30263026
// Helper functions for mutable getters
30273027
impl NodeNetworkInterface {
3028-
pub fn upstream_chain_nodes(&mut self, network_path: &[NodeId]) -> Vec<NodeId> {
3028+
pub fn upstream_chain_nodes(&self, network_path: &[NodeId]) -> Vec<NodeId> {
30293029
let Some(selected_nodes) = self.selected_nodes_in_nested_network(network_path) else {
30303030
log::error!("Could not get selected nodes in upstream_chain_nodes");
30313031
return Vec::new();
@@ -3156,7 +3156,7 @@ impl NodeNetworkInterface {
31563156
self.document_metadata.document_to_viewport = transform;
31573157
}
31583158

3159-
pub fn is_eligible_to_be_layer(&mut self, node_id: &NodeId, network_path: &[NodeId]) -> bool {
3159+
pub fn is_eligible_to_be_layer(&self, node_id: &NodeId, network_path: &[NodeId]) -> bool {
31603160
let Some(node) = self.document_node(node_id, network_path) else {
31613161
log::error!("Could not get node {node_id} in is_eligible_to_be_layer");
31623162
return false;
@@ -3362,6 +3362,24 @@ impl NodeNetworkInterface {
33623362
.map(|[a, b]| [node_graph_to_viewport.transform_point2(a), node_graph_to_viewport.transform_point2(b)])
33633363
}
33643364

3365+
pub fn selected_layers_artwork_bounding_box_viewport(&self) -> Option<[DVec2; 2]> {
3366+
self.selected_nodes()
3367+
.0
3368+
.iter()
3369+
.filter(|node| self.is_layer(&node, &[]))
3370+
.filter_map(|layer| self.document_metadata.bounding_box_viewport(LayerNodeIdentifier::new(*layer, self)))
3371+
.reduce(Quad::combine_bounds)
3372+
}
3373+
3374+
pub fn selected_unlocked_layers_bounding_box_viewport(&self) -> Option<[DVec2; 2]> {
3375+
self.selected_nodes()
3376+
.0
3377+
.iter()
3378+
.filter(|node| self.is_layer(&node, &[]) && !self.is_layer(&node, &[]))
3379+
.filter_map(|layer| self.document_metadata.bounding_box_viewport(LayerNodeIdentifier::new(*layer, self)))
3380+
.reduce(Quad::combine_bounds)
3381+
}
3382+
33653383
/// Get the combined bounding box of the click targets of the selected nodes in the node graph in layer space
33663384
pub fn selected_nodes_bounding_box(&mut self, network_path: &[NodeId]) -> Option<[DVec2; 2]> {
33673385
let Some(selected_nodes) = self.selected_nodes_in_nested_network(network_path) else {
@@ -3451,7 +3469,7 @@ impl NodeNetworkInterface {
34513469

34523470
let Some(first_root_layer) = self
34533471
.upstream_flow_back_from_nodes(vec![root_node.node_id], &[], FlowType::PrimaryFlow)
3454-
.find_map(|node_id| if self.is_layer(&node_id, &[]) { Some(LayerNodeIdentifier::new(node_id, self, &[])) } else { None })
3472+
.find_map(|node_id| if self.is_layer(&node_id, &[]) { Some(LayerNodeIdentifier::new(node_id, self)) } else { None })
34553473
else {
34563474
return;
34573475
};
@@ -3467,7 +3485,7 @@ impl NodeNetworkInterface {
34673485
if horizontal_root_node_id == first_root_layer.to_node() {
34683486
for current_node_id in horizontal_flow_iter {
34693487
if self.is_layer(&current_node_id, &[]) {
3470-
let current_layer_node = LayerNodeIdentifier::new(current_node_id, self, &[]);
3488+
let current_layer_node = LayerNodeIdentifier::new(current_node_id, self);
34713489
if !self.document_metadata.structure.contains_key(&current_layer_node) {
34723490
if current_node_id == first_root_layer.to_node() {
34733491
awaiting_primary_flow.push((current_node_id, LayerNodeIdentifier::ROOT_PARENT));
@@ -3484,7 +3502,7 @@ impl NodeNetworkInterface {
34843502
// Skip the horizontal_root_node_id node
34853503
for current_node_id in horizontal_flow_iter.skip(1) {
34863504
if self.is_layer(&current_node_id, &[]) {
3487-
let current_layer_node = LayerNodeIdentifier::new(current_node_id, self, &[]);
3505+
let current_layer_node = LayerNodeIdentifier::new(current_node_id, self);
34883506
if !self.document_metadata.structure.contains_key(&current_layer_node) {
34893507
awaiting_primary_flow.push((current_node_id, parent_layer_node));
34903508
children.push((parent_layer_node, current_layer_node));
@@ -3505,7 +3523,7 @@ impl NodeNetworkInterface {
35053523
for current_node_id in primary_flow_iter.skip(1) {
35063524
if self.is_layer(&current_node_id, &[]) {
35073525
// Create a new layer for the top of each stack, and add it as a child to the previous parent
3508-
let current_layer_node = LayerNodeIdentifier::new(current_node_id, self, &[]);
3526+
let current_layer_node = LayerNodeIdentifier::new(current_node_id, self);
35093527
if !self.document_metadata.structure.contains_key(&current_layer_node) {
35103528
children.push(current_layer_node);
35113529

@@ -3568,7 +3586,7 @@ impl NodeNetworkInterface {
35683586
}
35693587

35703588
stack.extend(self_network_metadata.persistent_metadata.node_metadata.keys().map(|node_id| {
3571-
let mut current_path = path.clone();
3589+
let mut current_path: Vec<NodeId> = path.clone();
35723590
current_path.push(*node_id);
35733591
current_path
35743592
}));
@@ -5087,8 +5105,8 @@ impl NodeNetworkInterface {
50875105
}
50885106
self.unload_upstream_node_click_targets(vec![*node_id], network_path);
50895107
// Reload click target of the layer which encapsulate the chain
5090-
if let Some(downstream_layer) = self.downstream_layer(node_id, network_path) {
5091-
self.unload_node_click_targets(&downstream_layer.to_node(), network_path);
5108+
if let Some(downstream_layer) = self.downstream_layer_for_chain_node(node_id, network_path) {
5109+
self.unload_node_click_targets(&downstream_layer, network_path);
50925110
}
50935111
self.unload_all_nodes_bounding_box(network_path);
50945112
}
@@ -5205,7 +5223,7 @@ impl NodeNetworkInterface {
52055223

52065224
/// node_id is the first chain node, not the layer
52075225
fn set_upstream_chain_to_absolute(&mut self, node_id: &NodeId, network_path: &[NodeId]) {
5208-
let Some(downstream_layer) = self.downstream_layer(node_id, network_path) else {
5226+
let Some(downstream_layer) = self.downstream_layer_for_chain_node(node_id, network_path) else {
52095227
log::error!("Could not get downstream layer in set_upstream_chain_to_absolute");
52105228
return;
52115229
};
@@ -5218,7 +5236,7 @@ impl NodeNetworkInterface {
52185236
if self.is_chain(upstream_id, network_path) {
52195237
self.set_absolute_position(upstream_id, previous_position, network_path);
52205238
// Reload click target of the layer which used to encapsulate the chain
5221-
self.unload_node_click_targets(&downstream_layer.to_node(), network_path);
5239+
self.unload_node_click_targets(&downstream_layer, network_path);
52225240
}
52235241
// If there is an upstream layer then stop breaking the chain
52245242
else {
@@ -5297,8 +5315,8 @@ impl NodeNetworkInterface {
52975315
// Deselect chain nodes upstream from a selected layer
52985316
if self.is_chain(selected_node, network_path)
52995317
&& self
5300-
.downstream_layer(selected_node, network_path)
5301-
.is_some_and(|downstream_layer| node_ids.contains(&downstream_layer.to_node()))
5318+
.downstream_layer_for_chain_node(selected_node, network_path)
5319+
.is_some_and(|downstream_layer| node_ids.contains(&downstream_layer))
53025320
{
53035321
node_ids.remove(selected_node);
53045322
}

editor/src/messages/tool/transform_layer/transform_layer_message_handler.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1323,7 +1323,7 @@ mod test_transform_layer {
13231323
let document = editor.active_document_mut();
13241324
let group_children = document.network_interface.downstream_layers(&group_layer.to_node(), &[]);
13251325
if !group_children.is_empty() {
1326-
Some(LayerNodeIdentifier::new(group_children[0], &document.network_interface, &[]))
1326+
Some(LayerNodeIdentifier::new(group_children[0], &document.network_interface))
13271327
} else {
13281328
None
13291329
}

0 commit comments

Comments
 (0)