[−][src]Struct kagura::Events
Events for Html
Fields
handlers: HashMap<String, Box<dyn FnMut(Event) -> Msg>>
Methods
impl<Msg> Events<Msg>
[src]
pub fn new() -> Self
[src]
Creates new empty Events
pub fn on(
self,
type_: impl Into<String>,
handler: impl FnMut(Event) -> Msg + 'static
) -> Self
[src]
self,
type_: impl Into<String>,
handler: impl FnMut(Event) -> Msg + 'static
) -> Self
Adds event handler
pub fn on_click(self, handler: impl FnMut(MouseEvent) -> Msg + 'static) -> Self
[src]
pub fn on_contextmenu(
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
pub fn on_dblclick(
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
pub fn on_mousedown(
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
pub fn on_mouseenter(
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
pub fn on_mouseleave(
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
pub fn on_mousemove(
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
pub fn on_mouseover(
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
pub fn on_mouseout(
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
pub fn on_mouseup(
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(MouseEvent) -> Msg + 'static
) -> Self
pub fn on_drag(self, handler: impl FnMut(DragEvent) -> Msg + 'static) -> Self
[src]
pub fn on_dragend(self, handler: impl FnMut(DragEvent) -> Msg + 'static) -> Self
[src]
pub fn on_dragenter(
self,
handler: impl FnMut(DragEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(DragEvent) -> Msg + 'static
) -> Self
pub fn on_dragstart(
self,
handler: impl FnMut(DragEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(DragEvent) -> Msg + 'static
) -> Self
pub fn on_dragleave(
self,
handler: impl FnMut(DragEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(DragEvent) -> Msg + 'static
) -> Self
pub fn on_dragover(
self,
handler: impl FnMut(DragEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(DragEvent) -> Msg + 'static
) -> Self
pub fn on_drop(self, handler: impl FnMut(DragEvent) -> Msg + 'static) -> Self
[src]
pub fn on_keydown(
self,
handler: impl FnMut(KeyboardEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(KeyboardEvent) -> Msg + 'static
) -> Self
pub fn on_keypress(
self,
handler: impl FnMut(KeyboardEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(KeyboardEvent) -> Msg + 'static
) -> Self
pub fn on_keyup(
self,
handler: impl FnMut(KeyboardEvent) -> Msg + 'static
) -> Self
[src]
self,
handler: impl FnMut(KeyboardEvent) -> Msg + 'static
) -> Self
pub fn on_input(self, handler: impl FnMut(String) -> Msg + 'static) -> Self
[src]
Auto Trait Implementations
impl<Msg> !Send for Events<Msg>
impl<Msg> Unpin for Events<Msg>
impl<Msg> !Sync for Events<Msg>
impl<Msg> !RefUnwindSafe for Events<Msg>
impl<Msg> !UnwindSafe for Events<Msg>
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,