Table of Contents

Class EndAnimationBehavior

Namespace
AlohaKit.Animations
Assembly
AlohaKit.Animations.dll

The EndAnimationBehavior class provides functionality to automatically stop an animation when the behavior is attached to a visual element. It ensures the animation is associated with the element and invokes the End method on the animation.

public class EndAnimationBehavior : Behavior<VisualElement>, INotifyPropertyChanged
Inheritance
EndAnimationBehavior
Implements
Inherited Members

Fields

AnimationProperty

Bindable property for specifying the animation to be executed when the behavior is attached.

public static readonly BindableProperty AnimationProperty

Field Value

BindableProperty

Properties

Animation

Gets or sets the animation to be executed when the behavior is attached.

public AnimationBase Animation { get; set; }

Property Value

AnimationBase

Methods

OnAttachedTo(VisualElement)

Called when the behavior is attached to a visual element. Associates the animation with the element and ends the animation.

protected override void OnAttachedTo(VisualElement bindable)

Parameters

bindable VisualElement

The visual element to which the behavior is attached.

OnDetachingFrom(VisualElement)

Called when the behavior is detached from a visual element. Clears the association with the visual element.

protected override void OnDetachingFrom(VisualElement bindable)

Parameters

bindable VisualElement

The visual element from which the behavior is detached.