Skip to main content

InteractiveElementExt

Trait InteractiveElementExt 

Source
pub trait InteractiveElementExt: InteractiveElement {
    // Provided methods
    fn lock_scroll_axis(self) -> Self
       where Self: Sized + StatefulInteractiveElement { ... }
    fn on_double_click(
        self,
        listener: impl Fn(&ClickEvent, &mut Window, &mut App) + 'static,
    ) -> Self
       where Self: Sized { ... }
}

Provided Methods§

Source

fn lock_scroll_axis(self) -> Self

Locks scrolling to the gesture’s dominant axis, where the platform supports it. See OngoingScrollExt for why this is a no-op on wasm32.

Source

fn on_double_click( self, listener: impl Fn(&ClickEvent, &mut Window, &mut App) + 'static, ) -> Self
where Self: Sized,

Set the listener for a double click event.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl<E: InteractiveElement> InteractiveElementExt for Stateful<E>

Implementors§