Files
aistudio-wpf-diagram/AIStudio.Wpf.DiagramDesigner/ViewModels/AdditionViewModel/AnimationViewModel.cs
2023-04-29 15:29:22 +08:00

97 lines
2.0 KiB
C#

using System;
using System.Windows.Media;
namespace AIStudio.Wpf.DiagramDesigner
{
[Serializable]
public class AnimationViewModel : BindableBase, IAnimationViewModel
{
private LineAnimation _lineAnimation = LineAnimation.None;
[CanDo]
public LineAnimation LineAnimation
{
get
{
return _lineAnimation;
}
set
{
SetProperty(ref _lineAnimation, value);
}
}
private double _duration = 1;
[CanDo]
public double Duration
{
get
{
return _duration;
}
set
{
SetProperty(ref _duration, value);
}
}
private Color _color = Colors.Red;
[CanDo]
public Color Color
{
get
{
return _color;
}
set
{
if (!SetProperty(ref _color, value))
{
RaisePropertyChanged(nameof(Color));
}
}
}
private string _path = "M 10,20 A 20,20 0 1 1 50,20 A 20,20 0 1 1 10,20";
[CanDo]
public string Path
{
get
{
return _path;
}
set
{
SetProperty(ref _path, value);
}
}
private double _witdh;
[CanDo]
public double Width
{
get
{
return _witdh;
}
set
{
SetProperty(ref _witdh, value);
}
}
private double _height;
[CanDo]
public double Height
{
get
{
return _height;
}
set
{
SetProperty(ref _height, value);
}
}
}
}