diff --git a/ezgui/src/widgets/spinner.rs b/ezgui/src/widgets/spinner.rs index 9b10e5f28f..dec1a1ca24 100644 --- a/ezgui/src/widgets/spinner.rs +++ b/ezgui/src/widgets/spinner.rs @@ -85,6 +85,7 @@ impl WidgetImpl for Spinner { self.current -= 1; } ctx.no_op_event(true, |ctx| self.down.event(ctx, output)); + return; } if let Some(pt) = ctx.canvas.get_cursor_in_screen_space() { @@ -92,9 +93,11 @@ impl WidgetImpl for Spinner { if let Some((_, dy)) = ctx.input.get_mouse_scroll() { if dy > 0.0 && self.current != self.high { self.current += 1; + output.outcome = Outcome::Changed; } if dy < 0.0 && self.current != self.low { self.current -= 1; + output.outcome = Outcome::Changed; } } } diff --git a/game/src/common/minimap.rs b/game/src/common/minimap.rs index ee2d13f6cd..4860eb34d0 100644 --- a/game/src/common/minimap.rs +++ b/game/src/common/minimap.rs @@ -193,13 +193,13 @@ impl Minimap { app.unzoomed_agents.bikes = self.composite.is_checked("Bike"); app.unzoomed_agents.buses_and_trains = self.composite.is_checked("Bus"); app.unzoomed_agents.peds = self.composite.is_checked("Pedestrian"); + if self.composite.has_widget("zorder") { + app.primary.show_zorder = self.composite.spinner("zorder"); + } self.composite = make_minimap_panel(ctx, app, self.zoom_lvl); } _ => {} } - if self.composite.has_widget("zorder") { - app.primary.show_zorder = self.composite.spinner("zorder"); - } if self.zoomed { let inner_rect = self.composite.rect_of("minimap");