FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    IActivationForViewFetcher

    trait · ferroui-reactiveui · v0.5.0

    trait IActivationForViewFetcher
    

    Tells when a view is activated and deactivated (IActivationForViewFetcher); usually only the integration of a user-interface toolkit implements it.

    A fetcher translates the signals of a toolkit (the view entering or leaving the visual tree, navigation, visibility) into activation. Several fetchers are registered in AppLocator as dyn IActivationForViewFetcher; for a view, the one with the highest affinity is used.

    The integration with FerroUI registers the fetcher of its controls; a test registers a fetcher of its own, as upstream's tests do.

    View source

    Members

    get_affinity_for_view

    fn get_affinity_for_view(self: &Self, view: &dyn IActivatableView) -> i32
    

    How well this fetcher can activate view: zero when it cannot, a positive score when it can, where the highest score wins (GetAffinityForView).

    Source

    get_activation_for_view

    fn get_activation_for_view(self: &Self, view: &Rc<dyn IActivatableView>) -> Rc<dyn IObservable<bool>>
    

    The activation of view: true when it is activated, false when it is deactivated (GetActivationForView). Called after get_affinity_for_view.

    Source

    Trait implementations

    Availability

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