ISelectionAdapter
trait · ferroui-controls · v0.5.0
trait ISelectionAdapter
Defines an item collection, selection members, and key handling for the
selection adapter contained in the drop-down portion of an
AutoCompleteBox control.
A class states that it is a selection adapter by listing
Rc<dyn ISelectionAdapter> among the interfaces of its class info.
Members
selected_itemset_selected_itemselection_changeditems_sourceset_items_sourcecommitcancelhandle_key_down
selected_item
fn selected_item(self: &Self) -> Option<BoxedValue>
Gets the selected item.
set_selected_item
fn set_selected_item(self: &Self, value: Option<BoxedValue>)
Sets the selected item.
selection_changed
fn selection_changed(self: &Self, handler: Rc<dyn Fn(&SelectionChangedEventArgs) -> ()>) -> Rc<dyn IDisposable>
Occurs when the SelectedItem property value changes.
items_source
fn items_source(self: &Self) -> Option<ItemsSource>
Gets a collection that is used to generate content for the selection adapter.
set_items_source
fn set_items_source(self: &Self, value: Option<ItemsSource>)
Sets a collection that is used to generate content for the selection adapter.
commit
fn commit(self: &Self, handler: Rc<dyn Fn(&RoutedEventArgs) -> ()>) -> Rc<dyn IDisposable>
Occurs when a selected item is not cancelled and is committed as the selected item.
cancel
fn cancel(self: &Self, handler: Rc<dyn Fn(&RoutedEventArgs) -> ()>) -> Rc<dyn IDisposable>
Occurs when a selection has been cancelled.
handle_key_down
fn handle_key_down(self: &Self, e: &KeyEventArgs)
Provides handling for the key down event that occurs when a key is
pressed while the drop-down portion of the
AutoCompleteBox has focus.
Trait implementations
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.