remove: unused layer

This commit is contained in:
mtvare6 2025-07-06 10:31:52 +05:30 committed by Keavon Chambers
parent 7d46c7dcfd
commit a0115ff54e
2 changed files with 2 additions and 4 deletions

View file

@ -224,7 +224,7 @@ impl Pivot {
self.pivot = Some(self.transform_from_normalized.transform_point2(self.normalized_pivot));
}
pub fn recalculate_pivot_for_layer(&mut self, document: &DocumentMessageHandler, layer: LayerNodeIdentifier, bounds: Option<[DVec2; 2]>) {
pub fn recalculate_pivot_for_layer(&mut self, document: &DocumentMessageHandler, bounds: Option<[DVec2; 2]>) {
if !self.active {
return;
}

View file

@ -72,7 +72,6 @@ fn calculate_pivot(
viewspace: DAffine2,
get_location: impl Fn(&ManipulatorPointId) -> Option<DVec2>,
dot: &mut Dot,
layers: LayerNodeIdentifier,
) -> (Option<(DVec2, DVec2)>, Option<[DVec2; 2]>) {
let average_position = || {
let mut point_count = 0;
@ -89,7 +88,7 @@ fn calculate_pivot(
Some([point, point])
}
});
dot.pivot.recalculate_pivot_for_layer(document, layers, bounds);
dot.pivot.recalculate_pivot_for_layer(document, bounds);
let position = || {
{
if dot.state.enabled {
@ -254,7 +253,6 @@ impl MessageHandler<TransformLayerMessage, TransformData<'_>> for TransformLayer
viewspace,
|point: &ManipulatorPointId| get_location(&point),
&mut self.dot,
selected_layers[0],
) {
*selected.pivot = new_pivot;
self.path_bounds = bounds;