Skip to main content

pump_events_until

Function pump_events_until 

Source
pub fn pump_events_until(limit: f64, ready: impl FnMut() -> bool)
Expand description

pump_until, but dequeuing application events as well.

Anything waiting on a synthetic click needs this rather than pump_until: turning the run loop does not drain the application’s event queue, so the event that would satisfy ready never arrives and the wait always runs to its limit.