Trait pixel_widgets::EventLoop[][src]

pub trait EventLoop<T: Send>: Clone + Send {
    type Error;
    fn send_event(&self, event: T) -> Result<(), Self::Error>;
}
Expand description

Trait for sending custom events to the event loop of the application

Associated Types

type Error[src]

The error returned when send_event fails

Required methods

fn send_event(&self, event: T) -> Result<(), Self::Error>[src]

Sends custom event to the event loop. Returns an Err if sending failed, for example when the event loop doesn’t exist anymore.

Implementations on Foreign Types

impl<T: Send> EventLoop<T> for EventLoopProxy<T>[src]

type Error = EventLoopClosed<T>

fn send_event(&self, event: T) -> Result<(), Self::Error>[src]

Implementors