[][src]Struct pixel_widgets::widget::dropdown::Dropdown

pub struct Dropdown<'a, T> { /* fields omitted */ }

Pick an item from a dropdown box

Implementations

impl<'a, T: 'a> Dropdown<'a, T>[src]

pub fn new(state: &'a mut State) -> Self[src]

Construct a new dropdown

pub fn push(self, item: impl IntoNode<'a, T>, on_select: T) -> Self[src]

Add an item to the dropdown.

pub fn extend(
    self,
    items: impl IntoIterator<Item = (impl IntoNode<'a, T>, T)>
) -> Self
[src]

Add multiple items to the dropdown.

Trait Implementations

impl<'a, T: 'a> IntoNode<'a, T> for Dropdown<'a, T>[src]

impl<'a, T: 'a> Widget<'a, T> for Dropdown<'a, T>[src]

Auto Trait Implementations

impl<'a, T> !RefUnwindSafe for Dropdown<'a, T>

impl<'a, T> !Send for Dropdown<'a, T>

impl<'a, T> !Sync for Dropdown<'a, T>

impl<'a, T> Unpin for Dropdown<'a, T> where
    T: Unpin

impl<'a, T> !UnwindSafe for Dropdown<'a, T>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Any for T where
    T: Any

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.