async-winit
async-winit copied to clipboard
Use winit like the async runtime you've always wanted
This pull request updates the winit dependency to 0.29.15 and fixes things that broke.
Our current "block inside of the event handler" strategy for holding events doesn't work on the Web. I'm not sure if there is a solid way for this to translate...
Many common patterns of GUI usage rely on being able to intercept events, making them unavailable for the rest of the system. It would be nice to be able to...
```rust use std::time::Duration; use async_winit::event_loop::{EventLoop, EventLoopBuilder}; use async_winit::window::Window; use async_winit::{DefaultThreadSafety, Timer}; use futures_lite::prelude::*; fn main() { main2(EventLoopBuilder::new().build()) } fn main2(evl: EventLoop) { let target = evl.window_target().clone(); evl.block_on(async move { //...