Trait winit_modular::event::UserEventTrait
source · [−]pub trait UserEventTrait: Any + Debug + Send {
fn rough_eq(&self, other: &dyn UserEventTrait) -> bool;
fn clone(&self) -> Box<dyn UserEventTrait>;
}Expand description
Traits which custom events must implement.
Custom events must support testing for equality because Event is.
If you don’t need this you can create a dummy implementation which always returns false.
They must implement cloning and Send because they will get cloned and sent to each proxy.
They must implement Any so they can be downcasted.
Required Methods
fn rough_eq(&self, other: &dyn UserEventTrait) -> bool
fn rough_eq(&self, other: &dyn UserEventTrait) -> bool
Custom events must support testing for equality because Event is.
If you don’t need this you can create a dummy implementation which always returns false.