Trait guion::event::Event[][src]

pub trait Event<E>: Sized + Clone + Debug where
    E: Env,
    E::Backend: Backend<E, Event = Self>, 
{ type Dest: Destination; type Key: Key; fn consuming(&self) -> bool;
fn destination(&self) -> Self::Dest;
fn _root_only(&self) -> bool;
fn _debug_type_name(&self); fn from<V: Variant<E>>(v: V) -> Self
    where
        Self: VariantSupport<V, E>
, { ... }
fn is<V: Variant<E>>(&self) -> Option<V>
    where
        Self: VariantSupport<V, E>
, { ... }
fn in_bounds(&self, _: &Bounds) -> bool { ... } }

an Event holds one of the support Variant and can be downcasted to a specific Variant

Associated Types

Loading content...

Required methods

fn consuming(&self) -> bool[src]

True if container widgets should sent this to only one widget

fn destination(&self) -> Self::Dest[src]

Where there Event should be initially injected into the context

fn _root_only(&self) -> bool[src]

fn _debug_type_name(&self)[src]

Loading content...

Provided methods

fn from<V: Variant<E>>(v: V) -> Self where
    Self: VariantSupport<V, E>, 
[src]

Create the event from a variant

fn is<V: Variant<E>>(&self) -> Option<V> where
    Self: VariantSupport<V, E>, 
[src]

Try to cast the Event as a specific variant. Use this for filtering and reading events

fn in_bounds(&self, _: &Bounds) -> bool[src]

Loading content...

Implementors

impl<E, K, D> Event<E> for DynEvent<E, K, D> where
    E: Env,
    E::Backend: Backend<E, Event = Self>,
    D: Destination,
    K: Key
[src]

type Dest = D

type Key = K

Loading content...