ShowBehaviorBase
struct · ferroui-xaml-interactions-custom · v0.5.0
struct ShowBehaviorBase
Base class for behaviors that show a control in response to an event.
The class is abstract: a deriving class implements
AttachedToVisualTreeBehaviorImpl::on_attached_to_visual_tree_override to listen for its
event, and calls show when it fires.
Members
TYPEto_reftarget_control_propertyevent_routing_strategy_propertyconstructtarget_controlset_target_controlevent_routing_strategyset_event_routing_strategyshow
TYPE
const TYPE: &'static $crate::TypeInfo
The runtime type of this class.
to_ref
fn to_ref(self: &Self) -> $crate::Ref<ShowBehaviorBase>
Returns a strong reference to this object.
target_control_property
fn target_control_property() -> &'static StyledProperty<Option<ElementRef<Control>>>
Identifies the TargetControl property.
Deviation (DEVIATIONS.md, Behaviors): the behavior does not own the control, so the value is an element reference.
event_routing_strategy_property
fn event_routing_strategy_property() -> &'static StyledProperty<RoutingStrategies>
Identifies the EventRoutingStrategy property: the routing strategy used for the
triggering event.
construct
fn construct() -> Self
Creates the class data; see ferroui_base::FerroObject::construct.
target_control
fn target_control(self: &Self) -> Option<Ref<Control>>
Gets or sets the target control. Markup resolves a name given for it to the named element. This is a property of the object model.
set_target_control
fn set_target_control(self: &Self, value: impl Into<Nullable<Control>>)
event_routing_strategy
fn event_routing_strategy(self: &Self) -> RoutingStrategies
Gets or sets the routing strategy used for the triggering event.
set_event_routing_strategy
fn set_event_routing_strategy(self: &Self, value: RoutingStrategies)
show
fn show(self: &Self) -> bool
Shows the target_control when the behavior is triggered.
Returns true if the control was shown; otherwise, false.
Trait implementations
SendSyncFreezeUnsafeUnpinUnpinUnwindSafeRefUnwindSafeAttachedToVisualTreeBehaviorImplExtBorrow<T>BorrowMut<T>Into<U>From<T>TryInto<U>TryFrom<U>ReceiverAnyFerroObjectImplExtStyledElementImplExtClassDefaultsErasedDestructorIntoEitherDisposingBehaviorImplExtStyledElementBehaviorImplExtDerefUpcast<T>Upcast<ShowBehaviorBase>StaticTypeObjectTypeSubclassable<T>FerroObjectImplStyledElementImplStyledElementBehaviorImplDisposingBehaviorImplAttachedToVisualTreeBehaviorImpl
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.