mirror of
https://github.com/Artemis-RGB/Artemis
synced 2026-11-12 11:56:30 +00:00
Code cleanup
This commit is contained in:
1 parent
c97b479779
commit
f071871695
73 files changed
+372
-364
No files matched your search
@@ -9,9 +9,9 @@ namespace Artemis.Plugins.LayerBrushes.Color
|
||||
{
|
||||
public class ColorBrush : LayerBrush
|
||||
{
|
||||
private SKShader _shader;
|
||||
private List<SKColor> _testColors;
|
||||
private SKPaint _paint;
|
||||
private SKShader _shader;
|
||||
private readonly List<SKColor> _testColors;
|
||||
|
||||
public ColorBrush(Layer layer, ColorBrushSettings settings, LayerBrushDescriptor descriptor) : base(layer, settings, descriptor)
|
||||
{
|
||||
@@ -31,6 +31,8 @@ namespace Artemis.Plugins.LayerBrushes.Color
|
||||
Settings.PropertyChanged += (sender, args) => CreateShader();
|
||||
}
|
||||
|
||||
public new ColorBrushSettings Settings { get; }
|
||||
|
||||
private void CreateShader()
|
||||
{
|
||||
var center = new SKPoint(Layer.Rectangle.MidX, Layer.Rectangle.MidY);
|
||||
@@ -61,8 +63,6 @@ namespace Artemis.Plugins.LayerBrushes.Color
|
||||
oldPaint?.Dispose();
|
||||
}
|
||||
|
||||
public new ColorBrushSettings Settings { get; }
|
||||
|
||||
public override LayerBrushViewModel GetViewModel()
|
||||
{
|
||||
return new ColorBrushViewModel(this);
|
||||
|
||||
@@ -11,7 +11,7 @@ namespace Artemis.Plugins.LayerBrushes.Color
|
||||
ColorBrush = element;
|
||||
}
|
||||
|
||||
public new ColorBrush ColorBrush { get; }
|
||||
public ColorBrush ColorBrush { get; }
|
||||
public IEnumerable<ValueDescription> BrushTypes => EnumUtilities.GetAllValuesAndDescriptions(typeof(GradientType));
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<packages>
|
||||
<package id="MaterialDesignColors" version="1.2.0" targetFramework="net472" />
|
||||
<package id="SkiaSharp" version="1.68.1" targetFramework="net472" />
|
||||
|
||||
Reference in new issue
Block a user