async fn events_task(
    barrier: Arc<Barrier>,
    interval: Duration,
    shared: Arc<Shared>,
    initial_size: Vec2,
) -> Result<(), Error> {
    let mut reactor = Reactor::new(&shared);
    reactor.pre_loop(initial_size).await?;
    barrier.wait().await;
    reactor.react_loop(interval).await
}
/// The task that listens to events. Barrier must be shared between tasks
/// with the same given screen or event channel.
The task that listens to events. Barrier must be shared between tasks
with the same given screen or event channel.
The task that listens to events . Barrier must be shared between tasks with the same given screen or event channel .
async fn events_task(
    barrier: Arc<Barrier>,
    interval: Duration,
    shared: Arc<Shared>,
    initial_size: Vec2,
) -> Result<(), Error> {
    let mut reactor = Reactor::new(&shared);
    reactor.pre_loop(initial_size).await?;
    barrier.wait().await;
    reactor.react_loop(interval).await
}
async fn events_task ( barrier : Arc < Barrier > , interval : Duration , shared : Arc < Shared > , initial_size : Vec2 , ) -> Result < ( ) , Error > { let mut reactor = Reactor :: new ( & shared ) ; reactor . pre_loop ( initial_size ) . await ? ; barrier . wait ( ) . await ; reactor . react_loop ( interval ) . await }
The task that listens to events.
The task that listens to events .
barrier
Arc<Barrier>
interval
Duration
shared
Arc<Shared>
initial_size
Vec2
barrier
Arc<Barrier>
interval
Duration
shared
Arc<Shared>
initial_size
Vec2