Escape stays in the sketch (#1804) (#1836)

Thanks @thodoristsagko.
This commit is contained in:
Thodoris Tsagkogeorgas authored and GitHub committed 2026-10-17 04:07:26 -04:00
1 parent 337564190b
commit f3b5846e6b
2 files changed
+25 -3

No files matched your search

+2 -3
View File
@@ -1320,10 +1320,9 @@ pub fn shortcuts(app: &mut SolveApp, ctx: &egui::Context) {
} else if !app.session.selection.is_empty() || app.session.active_sketch.is_none() {
app.tree.picked_joints.clear();
let _ = app.run("select.clear", json!({}));
} else {
// Nothing left to cancel: Esc finishes the sketch.
app.finish_sketch();
}
// An open sketch with nothing left to cancel stays open (#1804). Finish Sketch
// is what leaves it, so a second Escape after putting a tool down is harmless.
}
Key::S if !mods.shift && !mods.alt => {
let at = ctx.input(|i| i.pointer.latest_pos());