Skip to main content

SourceEvent

Trait SourceEvent 

Source
pub trait SourceEvent: Clone + PartialEq {
    type Name: NameOfEvent;

    // Required methods
    fn is_pressed(&self) -> bool;
    fn is_moved(&self) -> bool;
    fn is_touch_released(&self) -> bool;
    fn try_location(&self) -> Option<CursorPoint>;
    fn as_event_name(&self) -> Self::Name;
}

Required Associated Types§

Required Methods§

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§