chore: use file-scoped namespace
This commit is contained in:
1 parent
99d2fafb72
commit
bbf1b7d4c6
748 files changed
+57929
-58678
No files matched your search
@@ -3,35 +3,34 @@ using System.Windows;
|
||||
using System.Windows.Media.Effects;
|
||||
using HandyControl.Data;
|
||||
|
||||
namespace HandyControl.Media.Effects
|
||||
namespace HandyControl.Media.Effects;
|
||||
|
||||
public class GrayScaleEffect : EffectBase
|
||||
{
|
||||
public class GrayScaleEffect : EffectBase
|
||||
private static readonly PixelShader Shader;
|
||||
|
||||
static GrayScaleEffect()
|
||||
{
|
||||
private static readonly PixelShader Shader;
|
||||
|
||||
static GrayScaleEffect()
|
||||
Shader = new PixelShader
|
||||
{
|
||||
Shader = new PixelShader
|
||||
{
|
||||
UriSource = new Uri("pack://application:,,,/HandyControl;component/Resources/Effects/GrayScaleEffect.ps")
|
||||
};
|
||||
}
|
||||
|
||||
public GrayScaleEffect()
|
||||
{
|
||||
PixelShader = Shader;
|
||||
|
||||
UpdateShaderValue(InputProperty);
|
||||
UpdateShaderValue(ScaleProperty);
|
||||
}
|
||||
|
||||
public static readonly DependencyProperty ScaleProperty = DependencyProperty.Register(
|
||||
"Scale", typeof(double), typeof(GrayScaleEffect), new PropertyMetadata(ValueBoxes.Double1Box, PixelShaderConstantCallback(0)));
|
||||
|
||||
public double Scale
|
||||
{
|
||||
get => (double) GetValue(ScaleProperty);
|
||||
set => SetValue(ScaleProperty, value);
|
||||
}
|
||||
UriSource = new Uri("pack://application:,,,/HandyControl;component/Resources/Effects/GrayScaleEffect.ps")
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
public GrayScaleEffect()
|
||||
{
|
||||
PixelShader = Shader;
|
||||
|
||||
UpdateShaderValue(InputProperty);
|
||||
UpdateShaderValue(ScaleProperty);
|
||||
}
|
||||
|
||||
public static readonly DependencyProperty ScaleProperty = DependencyProperty.Register(
|
||||
"Scale", typeof(double), typeof(GrayScaleEffect), new PropertyMetadata(ValueBoxes.Double1Box, PixelShaderConstantCallback(0)));
|
||||
|
||||
public double Scale
|
||||
{
|
||||
get => (double) GetValue(ScaleProperty);
|
||||
set => SetValue(ScaleProperty, value);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user