DeferWithRedrawAsync

Trait DeferWithRedrawAsync 

Source
pub trait DeferWithRedrawAsync<T: 'static> {
    // Required method
    fn defer_with_redraw_async<R>(
        self,
        f: impl AsyncDeferCallback<T, R>,
    ) -> impl Future<Output = Option<R>> + Send
       where R: Send + 'static,
             Self: Sized;
}
Expand description

Async extension to [UiRunner], allowing to await until deferred closures with redraw are executed

Required Methods§

Source

fn defer_with_redraw_async<R>( self, f: impl AsyncDeferCallback<T, R>, ) -> impl Future<Output = Option<R>> + Send
where R: Send + 'static, Self: Sized,

Awaitable variant of [DeferWithRedraw::defer_with_redraw] based on DeferAsync::defer_async.

Return value behaves the same as DeferAsync::defer_async.

Implementations on Foreign Types§

Source§

impl<W: Widget + 'static> DeferWithRedrawAsync<W> for UiRunner<W>

Source§

async fn defer_with_redraw_async<R: Send + 'static>( self, f: impl AsyncDeferCallback<W, R>, ) -> Option<R>

Implementors§