Enum virtual_node::event::EventHandler [−][src]
pub enum EventHandler {
NoArgs(Rc<RefCell<dyn FnMut()>>),
MouseEvent(Rc<RefCell<dyn FnMut(MouseEvent)>>),
UnsupportedSignature(EventAttribFn),
}Expand description
Event handlers such as the closure in onclick = |event| {}.
Cloning
Can be cheaply cloned since since inner types are reference counted.
Variants
A callback that does not contain any arguments.
MouseEvent(Rc<RefCell<dyn FnMut(MouseEvent)>>)Handle mouse events such as onclick and oninput
Tuple Fields of MouseEvent
0: Rc<RefCell<dyn FnMut(MouseEvent)>>UnsupportedSignature(EventAttribFn)EventHandler’s that we do not have a dedicated type for. This is useful for custom events.
Tuple Fields of UnsupportedSignature
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for EventHandler
impl !Send for EventHandler
impl !Sync for EventHandler
impl Unpin for EventHandler
impl !UnwindSafe for EventHandler
Blanket Implementations
Mutably borrows from an owned value. Read more