Trait cosmic::widget::segmented_button::Selectable

source ·
pub trait Selectable {
    // Required methods
    fn activate(&mut self, id: Entity);
    fn deactivate(&mut self, id: Entity);
    fn is_active(&self, id: Entity) -> bool;
}
Expand description

Describes a type that has selectable items.

Required Methods§

source

fn activate(&mut self, id: Entity)

Activate an item.

source

fn deactivate(&mut self, id: Entity)

Deactivate an item.

source

fn is_active(&self, id: Entity) -> bool

Checks if the item is active.

Implementors§