pub struct EventDispatcher { /* private fields */ }Expand description
Event dispatcher for managing event listeners
Implementations§
Source§impl EventDispatcher
impl EventDispatcher
Sourcepub fn add_listener(&self, element_id: String, listener: EventListener)
pub fn add_listener(&self, element_id: String, listener: EventListener)
Add an event listener
Sourcepub fn remove_listeners(&self, element_id: &str)
pub fn remove_listeners(&self, element_id: &str)
Remove all listeners for an element
Trait Implementations§
Auto Trait Implementations§
impl Freeze for EventDispatcher
impl RefUnwindSafe for EventDispatcher
impl Send for EventDispatcher
impl Sync for EventDispatcher
impl Unpin for EventDispatcher
impl UnwindSafe for EventDispatcher
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more