Skip to content

DesignCraft: An open-source page and layout design editor written by scratch in pure Rust

Merge fix: a Shift-click release keeps the other selected objects

moppeeer66b51ee15f4d
diff --git a/crates/tools/src/select.rs b/crates/tools/src/select.rs
index 99b45a0ee..cafddc699 100644
--- a/crates/tools/src/select.rs
+++ b/crates/tools/src/select.rs
@@ -1232,7 +1232,7 @@ impl Tool for SelectionTool {
// A Shift-click on a selected point that never became a drag takes it away.
Drag::Anchor { .. } if anchor_release.is_some() => {
let points: Vec<_> = cx.selection.anchors.iter().copied().filter(|a| Some(*a) != anchor_release).collect();
- vec![Action::Commit, Action::Exec("selection.set".into(), anchor_selection(cx, &points))]
+ vec![Action::Commit, Action::Exec("selection.set".into(), anchor_selection(cx, &points, true))]
}
Drag::Move { .. }
| Drag::Resize { .. }