FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    SelectionModelImpl

    trait · ferroui-controls · v0.5.0

    trait SelectionModelImpl<T: PropertyValue>
    

    The members of SelectionModel that a type deriving from it can override.

    Every method receives the model and defaults to the model's own implementation, which is the base_* method of the same name: an override calls it where the managed code calls the base implementation. A deriving type owns its model, implements this trait and registers itself with SelectionModel::set_derived; every virtual call the model makes (from its public members and from the handling of source collection changes) then goes through the override. See the module documentation of selection.

    View source

    Members

    set_source

    fn set_source(self: &Self, model: &SelectionModel<T>, value: Option<ItemsSource>)
    

    Source

    on_source_collection_change_started

    fn on_source_collection_change_started(self: &Self, model: &SelectionModel<T>)
    

    Source

    on_source_collection_changed

    fn on_source_collection_changed(self: &Self, model: &SelectionModel<T>, e: &ItemsChangedEventArgs<'_>)
    

    Source

    on_source_collection_change_finished

    fn on_source_collection_change_finished(self: &Self, model: &SelectionModel<T>)
    

    Source

    on_indexes_changed

    fn on_indexes_changed(self: &Self, model: &SelectionModel<T>, shift_index: i32, shift_delta: i32)
    

    Source

    on_source_reset

    fn on_source_reset(self: &Self, model: &SelectionModel<T>)
    

    Source

    on_selection_removed

    fn on_selection_removed(self: &Self, model: &SelectionModel<T>, index: i32, count: i32, deselected_items: Vec<Option<T>>)
    

    Source

    on_items_added

    fn on_items_added(self: &Self, model: &SelectionModel<T>, index: i32, items: ItemsView<'_>) -> CollectionChangeState<T>
    

    Source

    on_items_removed

    fn on_items_removed(self: &Self, model: &SelectionModel<T>, index: i32, items: ItemsView<'_>) -> CollectionChangeState<T>
    

    Source

    is_valid_collection_change

    fn is_valid_collection_change(self: &Self, model: &SelectionModel<T>, e: &ItemsChangedEventArgs<'_>) -> bool
    

    Source

    Trait implementations

    Availability

    Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.