[][src]Struct nuki::compr::PropertyAction

pub struct PropertyAction { /* fields omitted */ }

An action typed property.

Implementations

impl PropertyAction[src]

pub fn with_button<F>(
    name: &'static str,
    text: &'static str,
    callback: Arc<RefCell<F>>
) -> Self where
    F: FnMut(&dyn Property, bool) -> bool + 'static, 
[src]

Create an Action Property with Push Button.

pub fn with_check_box<F>(
    name: &'static str,
    checked: bool,
    callback: Arc<RefCell<F>>
) -> Self where
    F: FnMut(&dyn Property, bool) -> bool + 'static, 
[src]

Create an Action Property with Check Box.

pub fn is_checked(&self) -> bool[src]

Returns current check state.

pub fn trigger(&self, checked: bool) -> bool[src]

Trigger the action callback and returning the final check state.

Trait Implementations

impl Debug for PropertyAction[src]

impl Default for PropertyAction[src]

impl Property for PropertyAction[src]

impl Send for PropertyAction[src]

impl Sync for PropertyAction[src]

Auto Trait Implementations

Blanket Implementations

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

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, 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.