mirror of
https://github.com/rust-windowing/winit.git
synced 2026-06-27 07:03:15 -04:00
On Web, use requestAnimationFrame for RedrawRequested
This commit is contained in:
committed by
Kirill Chibisov
parent
7a58fe58ce
commit
57fad2ce15
@@ -735,7 +735,10 @@ impl<T> EventLoopWindowTarget<T> {
|
||||
}
|
||||
|
||||
canvas_clone.borrow_mut().is_intersecting = Some(is_intersecting);
|
||||
})
|
||||
});
|
||||
|
||||
let runner = self.runner.clone();
|
||||
canvas.on_animation_frame(move || runner.request_redraw(RootWindowId(id)));
|
||||
}
|
||||
|
||||
pub fn available_monitors(&self) -> VecDequeIter<MonitorHandle> {
|
||||
|
||||
Reference in New Issue
Block a user