pub trait Event<Handler> {
// Required method
fn handle(&self, handler: &mut Handler);
}
Expand description
A trait for events that can modify input state.
Required Methods§
sourcefn handle(&self, handler: &mut Handler)
fn handle(&self, handler: &mut Handler)
Modify the state of the provided handler (for example, a Mouse
or
Keyboard
).
This should rarely be called directly. Instead, pass this event to
the handler’s handle_event
method.