Class AnimationView
Definition
- Namespace:
- ElmSharp
- Assembly:
- ElmSharp.dll
The AnimationView is designed to show and play animation of vector graphics based content. Currently ElmSharp AnimationView is supporting only json format (known for Lottie file as well).
[Obsolete("This has been deprecated in API12")]
public class AnimationView : EvasObject
- Inheritance
Constructors
View SourceAnimationView(EvasObject)
Creates and initializes a new instance of the AnimationView class.
Declaration
[Obsolete("This has been deprecated in API12")]
public AnimationView(EvasObject parent)
Parameters
Type | Name | Description |
---|---|---|
EvasObject | parent | The parent is a given container, which will be attached by AnimationView as a child. It's EvasObject type. |
Properties
View SourceAutoPlay
Sets or gets whether to play animation automatically.
Declaration
[Obsolete("This has been deprecated in API12")]
public bool AutoPlay { get; set; }
Property Value
Type | Description |
---|---|
bool |
AutoRepeat
Sets or gets whether to turn on/off animation looping.
Declaration
[Obsolete("This has been deprecated in API12")]
public bool AutoRepeat { get; set; }
Property Value
Type | Description |
---|---|
bool |
DefaultSize
Get the default view size that specified from vector resource.
Declaration
[Obsolete("This has been deprecated in API12")]
public Size DefaultSize { get; }
Property Value
Type | Description |
---|---|
Size |
DurationTime
Get the duration of animation in seconds.
Declaration
[Obsolete("This has been deprecated in API12")]
public double DurationTime { get; }
Property Value
Type | Description |
---|---|
double |
Remarks
Returns total duration time of current animation in the seconds. If current animation source isn't animatable, it returns zero.
Frame
Sets or gets current frame position of animation view.
Declaration
[Obsolete("This has been deprecated in API12")]
public int Frame { get; set; }
Property Value
Type | Description |
---|---|
int |
FrameCount
Get the index of end frame of the AnimationView, if it's animated.
Declaration
[Obsolete("This has been deprecated in API12")]
public int FrameCount { get; }
Property Value
Type | Description |
---|---|
int |
Remarks
Frame number starts with 0.
IsReversedPlaying
Get the status whether current animation is on playing forward or backward.
Declaration
[Obsolete("This has been deprecated in API12")]
public bool IsReversedPlaying { get; }
Property Value
Type | Description |
---|---|
bool |
Remarks
If AnimationView is not on playing, it will return False.
MaxFrame
Sets or Gets the last frame of the play
Declaration
[Obsolete("This has been deprecated in API12")]
public int MaxFrame { get; set; }
Property Value
Type | Description |
---|---|
int |
Remarks
Default value is FrameCount -1.
MaxProgress
Sets or Gets the last progress of the play
Declaration
[Obsolete("This has been deprecated in API12")]
public double MaxProgress { get; set; }
Property Value
Type | Description |
---|---|
double |
Remarks
Default value is 1.
MinFrame
Sets or Gets the start frame of the play
Declaration
[Obsolete("This has been deprecated in API12")]
public int MinFrame { get; set; }
Property Value
Type | Description |
---|---|
int |
Remarks
Default value is 0.
MinProgress
Sets or Gets the start progress of the play
Declaration
[Obsolete("This has been deprecated in API12")]
public double MinProgress { get; set; }
Property Value
Type | Description |
---|---|
double |
Remarks
Default value is 0.
Progress
Sets or gets current progress position of animation view.
Declaration
[Obsolete("This has been deprecated in API12")]
public double Progress { get; set; }
Property Value
Type | Description |
---|---|
double |
Speed
Sets or gets the animation speed.
Declaration
[Obsolete("This has been deprecated in API12")]
public double Speed { get; set; }
Property Value
Type | Description |
---|---|
double |
State
Get current animation view state.
Declaration
[Obsolete("This has been deprecated in API12")]
public AnimationViewState State { get; }
Property Value
Type | Description |
---|---|
AnimationViewState |
Methods
View SourceCreateHandle(EvasObject)
Creates a AnimationView handle.
Declaration
[Obsolete("This has been deprecated in API12")]
protected override IntPtr CreateHandle(EvasObject parent)
Parameters
Type | Name | Description |
---|---|---|
EvasObject | parent | Parent EvasObject. |
Returns
Type | Description |
---|---|
System.IntPtr | Handle IntPtr. |
Overrides
View SourcePause()
Pause current animation instantly.
Declaration
[Obsolete("This has been deprecated in API12")]
public void Pause()
Play()
Play animation one time instantly when it's available.
Declaration
[Obsolete("This has been deprecated in API12")]
public void Play()
Play(bool)
Play animation one time instantly when it's available.
Declaration
[Obsolete("This has been deprecated in API12")]
public void Play(bool isReverse)
Parameters
Type | Name | Description |
---|---|---|
bool | isReverse | Whether the animation play or reverse play. |
Resume()
Resume paused animation to continue animation.
Declaration
[Obsolete("This has been deprecated in API12")]
public void Resume()
Remarks
This resume must be called on animation paused status.
SetAnimation(string)
Sets the animation source file.
Declaration
[Obsolete("This has been deprecated in API12")]
public void SetAnimation(string file)
Parameters
Type | Name | Description |
---|---|---|
string | file | The animation file path. |
Stop()
Stop playing animation.
Declaration
[Obsolete("This has been deprecated in API12")]
public void Stop()
Events
View SourceFinished
It occurs when the animation is just finished.
Declaration
[Obsolete("This has been deprecated in API12")]
public event EventHandler Finished
Event Type
Type | Description |
---|---|
System.EventHandler |
Paused
It occurs when the animation is just paused.
Declaration
[Obsolete("This has been deprecated in API12")]
public event EventHandler Paused
Event Type
Type | Description |
---|---|
System.EventHandler |
Repeated
It occurs when the animation is just repeated.
Declaration
[Obsolete("This has been deprecated in API12")]
public event EventHandler Repeated
Event Type
Type | Description |
---|---|
System.EventHandler |
Resumed
It occurs when the animation is just resumed.
Declaration
[Obsolete("This has been deprecated in API12")]
public event EventHandler Resumed
Event Type
Type | Description |
---|---|
System.EventHandler |
Started
It occurs when the animation is just started.
Declaration
[Obsolete("This has been deprecated in API12")]
public event EventHandler Started
Event Type
Type | Description |
---|---|
System.EventHandler |
Stopped
It occurs when the animation is just stopped.
Declaration
[Obsolete("This has been deprecated in API12")]
public event EventHandler Stopped
Event Type
Type | Description |
---|---|
System.EventHandler |
Updated
It occurs when the animation is updated to the next frame.
Declaration
[Obsolete("This has been deprecated in API12")]
public event EventHandler Updated
Event Type
Type | Description |
---|---|
System.EventHandler |