Skip to content

Commit 9ffc32f

Browse files
committed
fix bugs
1 parent 22a4b42 commit 9ffc32f

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/ui.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,11 @@ fn start_game(config: &mut GameConfig, first_time: bool) -> Option<::std::thread
141141
return Some(::std::thread::spawn(|| Game::new(config).run()));
142142
}
143143
}
144-
144+
// Hot-fix for a bug: window does not redraw after
145+
// minimized and maximized again.
146+
if let glium::glutin::Event::Focused(true) = event {
147+
ui.needs_redraw();
148+
}
145149
// Draw the GUI
146150
if let Some(whatever) = ui.draw_if_changed() {
147151
renderer.fill(&display, whatever, &image_map);

0 commit comments

Comments
 (0)