fix(topola-egui): clamp timestep slider to 0.001-3.0 instead of 0.0-3.0

Timestep should never be set to 0 because this freezes the GUI if the
execution takes a long time.

Of course, this solution assumes that any lengthy operation is split
into sufficiently fine steppable steps.

Fixes https://codeberg.org/topola/topola/issues/203
This commit is contained in:
Mikolaj Wielgus 2025-04-26 03:57:16 +02:00
parent c2bdeb61e4
commit 640247a675
1 changed files with 1 additions and 1 deletions

View File

@ -109,7 +109,7 @@ impl MenuBar {
ui.label(tr.text("tr-menu-view-frame-timestep"));
ui.add(
egui::widgets::Slider::new(&mut self.frame_timestep, 0.0..=3.0)
egui::widgets::Slider::new(&mut self.frame_timestep, 0.001..=3.0)
.suffix(" s"),
);
});