[][src]Struct orbtk_api::event::EventQueue

pub struct EventQueue { /* fields omitted */ }

The EventQueue is used to register and read new events.

Implementations

impl EventQueue[src]

pub fn new() -> Self[src]

Creates a new event queue.

pub fn append(&mut self, other: &mut Vec<EventBox>)[src]

Appends a new event box.

pub fn register_event_with_strategy<E: Event>(
    &mut self,
    event: E,
    strategy: EventStrategy,
    source: Entity
)
[src]

Registers an event with a given event strategy and a source (Entity of a widget) where the event should start.

pub fn register_event<E: Event>(&mut self, event: E, source: Entity)[src]

pub fn dequeue(&mut self) -> Option<EventBox>[src]

Dequeue an event.

pub fn len(&self) -> usize[src]

Returns the number of events in the EventQueue.

pub fn is_empty(&self) -> bool[src]

If the EventQueue has more then zero events it will return true otherwise false.

Trait Implementations

impl Debug for EventQueue[src]

impl Default for EventQueue[src]

impl<'a> IntoIterator for &'a mut EventQueue[src]

type Item = EventBox

The type of the elements being iterated over.

type IntoIter = EventQueueIterator<'a>

Which kind of iterator are we turning this into?

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<E> Component for E where
    E: Any
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> SetParameter for T

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.