DesignCraft: An open-source page and layout design editor written by scratch in pure Rust
Integration: #1503 clippy: return the guide cursor match directly
aiongg9ff71e1d0a2e
diff --git a/crates/ui-egui/src/canvas.rs b/crates/ui-egui/src/canvas.rsindex 3177a8ed4..ed207c34b 100644--- a/crates/ui-egui/src/canvas.rs+++ b/crates/ui-egui/src/canvas.rs@@ -378,12 +378,11 @@ fn pointer_cursor(app: &mut DesignApp, ui: &egui::Ui, xf: &Xf, p: Pos2) -> Curso// canvas too (the tool's cursor took over as soon as the pointer left the ruler). Only// while the button is down: a drag state left behind by a skipped release doesn't stick.let dragging = ui.input(|i| i.pointer.primary_down());- let c = match ui.data(|d| d.get_temp::<GuideDrag>(egui::Id::unique(GUIDE_DRAG))).filter(|_| dragging).map(|g| g.orientation) {+ match ui.data(|d| d.get_temp::<GuideDrag>(egui::Id::unique(GUIDE_DRAG))).filter(|_| dragging).map(|g| g.orientation) {Some(designcraft_doc::Orientation::Horizontal) => Cursor::ResizeV,Some(designcraft_doc::Orientation::Vertical) => Cursor::ResizeH,None => c,- };- c+ }}/// Longest side of the loaded place cursor's thumbnail, in points.