[][src]Trait orbtk::prelude::EventHandler

pub trait EventHandler {
    fn handle_event(
        &self,
        state_context: &mut StatesContext<'_>,
        event: &EventBox
    ) -> bool;
fn handles_event(&self, event: &EventBox) -> bool; }

This trait is used to define an event handler.

Required methods

fn handle_event(
    &self,
    state_context: &mut StatesContext<'_>,
    event: &EventBox
) -> bool

Handles an event by the given widget. If it returns true the event will not be forwarded.

fn handles_event(&self, event: &EventBox) -> bool

Check if the handler could handle the given event box.

Loading content...

Implementors

impl EventHandler for ActivateEventHandler[src]

impl EventHandler for ChangedEventHandler[src]

impl EventHandler for ClickEventHandler[src]

impl EventHandler for FocusEventHandler[src]

impl EventHandler for GlobalMouseUpEventHandler[src]

impl EventHandler for KeyDownEventHandler[src]

impl EventHandler for MouseDownEventHandler[src]

impl EventHandler for MouseMoveEventHandler[src]

impl EventHandler for MouseUpEventHandler[src]

impl EventHandler for ScrollEventHandler[src]

impl EventHandler for SelectionChangedEventHandler[src]

impl EventHandler for WindowEventHandler[src]

Loading content...