FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    DragAndDropEventsBehavior

    struct · ferroui-xaml-interactions-draganddrop · v0.5.0

    struct DragAndDropEventsBehavior
    

    Base class for behaviors that respond to drag-and-drop events: the drag events of the target_control, or else of the associated control, go to the members of DragAndDropEventsBehaviorImpl.

    The class is abstract.

    View source

    Members

    TYPE

    const TYPE: &'static $crate::TypeInfo
    

    The runtime type of this class.

    Source

    to_ref

    fn to_ref(self: &Self) -> $crate::Ref<DragAndDropEventsBehavior>
    

    Returns a strong reference to this object.

    Source

    on_drag_enter

    fn on_drag_enter(self: &Self, sender: Option<&BoxedValue>, e: &DragEventArgs)
    

    Called when a drag-and-drop operation enters the element.

    Source

    on_drag_leave

    fn on_drag_leave(self: &Self, sender: Option<&BoxedValue>, e: &DragEventArgs)
    

    Called when a drag-and-drop operation leaves the element.

    Source

    on_drag_over

    fn on_drag_over(self: &Self, sender: Option<&BoxedValue>, e: &DragEventArgs)
    

    Called when a drag-and-drop operation is updated while over the element.

    Source

    on_drop

    fn on_drop(self: &Self, sender: Option<&BoxedValue>, e: &DragEventArgs)
    

    Called when a drag-and-drop operation should complete over the element.

    Source

    target_control_property

    fn target_control_property() -> &'static StyledProperty<Option<ElementRef<Control>>>
    

    Identifies the TargetControl property.

    Deviation (DEVIATIONS.md, Behaviors): the control is held by an element reference (a weak reference), as the framework holds the elements a property names.

    Source

    construct

    fn construct() -> Self
    

    Creates the class data; see ferroui_base::FerroObject::construct.

    Source

    target_control

    fn target_control(self: &Self) -> Option<Ref<Control>>
    

    Gets or sets the control that is used as source for drag and drop events.

    Source

    set_target_control

    fn set_target_control(self: &Self, value: Option<Ref<Control>>)
    

    Source

    Trait implementations

    Availability

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