From 5ef77efebb95d9bc1433cb85e04f3614e89c1f08 Mon Sep 17 00:00:00 2001 From: William Casarin Date: Tue, 3 Jun 2025 08:38:03 -0700 Subject: [PATCH] scroll: simple fix Instead of a complicated min scroll distance implementation, we simply disable drag to scroll on carousel to fix vertical scrolling on android --- crates/notedeck_ui/src/note/media.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/crates/notedeck_ui/src/note/media.rs b/crates/notedeck_ui/src/note/media.rs index a5d4a967..fcd47530 100644 --- a/crates/notedeck_ui/src/note/media.rs +++ b/crates/notedeck_ui/src/note/media.rs @@ -54,8 +54,11 @@ pub(crate) fn image_carousel( }; let mut action = None; + //let has_touch_screen = ui.ctx().input(|i| i.has_touch_screen()); + ui.add_sized([width, height], |ui: &mut egui::Ui| { egui::ScrollArea::horizontal() + .drag_to_scroll(false) .id_salt(carousel_id) .show(ui, |ui| { ui.horizontal(|ui| {