Implement revamped RedrawRequested on Windows (#1050)

* Move event loop runner to runner module

* Implement new redraw API
This commit is contained in:
Osspial 2019-08-26 22:05:42 -04:00
parent 0c151f9fb3
commit 8eb7853a1a
4 changed files with 466 additions and 428 deletions

View file

@ -20,7 +20,10 @@ fn main() {
event: WindowEvent::CloseRequested,
window_id,
} if window_id == window.id() => *control_flow = ControlFlow::Exit,
_ => *control_flow = ControlFlow::Wait,
Event::MainEventsCleared => {
window.request_redraw();
}
_ => *control_flow = ControlFlow::Poll,
}
});
}